Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
DCloud
hello uni-app x
提交
cb6378e0
H
hello uni-app x
项目概览
DCloud
/
hello uni-app x
通知
6005
Star
91
Fork
164
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
18
列表
看板
标记
里程碑
合并请求
1
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
H
hello uni-app x
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
18
Issue
18
列表
看板
标记
里程碑
合并请求
1
合并请求
1
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
cb6378e0
编写于
12月 16, 2023
作者:
雪洛
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
test: 屏蔽web端不支持的测试例
上级
c20ea6d2
变更
10
显示空白变更内容
内联
并排
Showing
10 changed file
with
79 addition
and
40 deletion
+79
-40
pages/API/element-takesnapshot/element-takesnapshot.test.js
pages/API/element-takesnapshot/element-takesnapshot.test.js
+6
-0
pages/API/get-app-authorize-setting/get-app-authorize-setting.test.js
...t-app-authorize-setting/get-app-authorize-setting.test.js
+6
-0
pages/API/get-battery-info/get-battery-info.test.js
pages/API/get-battery-info/get-battery-info.test.js
+7
-2
pages/API/get-element-by-id/get-element-by-id-multiple-root-node.test.js
...lement-by-id/get-element-by-id-multiple-root-node.test.js
+8
-2
pages/API/get-element-by-id/get-element-by-id.test.js
pages/API/get-element-by-id/get-element-by-id.test.js
+6
-0
pages/API/get-file-system-manager/get-file-system-manager.test.js
...I/get-file-system-manager/get-file-system-manager.test.js
+6
-1
pages/API/unicloud-database/unicloud-database.uvue
pages/API/unicloud-database/unicloud-database.uvue
+1
-1
pages/component/list-view/list-view-multiplex.test.js
pages/component/list-view/list-view-multiplex.test.js
+18
-19
pages/component/list-view/list-view.test.js
pages/component/list-view/list-view.test.js
+7
-8
pages/pages.test.js
pages/pages.test.js
+14
-7
未找到文件。
pages/API/element-takesnapshot/element-takesnapshot.test.js
浏览文件 @
cb6378e0
...
@@ -2,6 +2,12 @@ const PAGE_PATH = "/pages/API/element-takesnapshot/element-takesnapshot";
...
@@ -2,6 +2,12 @@ const PAGE_PATH = "/pages/API/element-takesnapshot/element-takesnapshot";
describe
(
"
element-takesnapshot
"
,
()
=>
{
describe
(
"
element-takesnapshot
"
,
()
=>
{
if
(
process
.
env
.
uniTestPlatformInfo
.
indexOf
(
'
web
'
)
>
-
1
)
{
it
(
'
dummyTest
'
,
()
=>
{
expect
(
1
).
toBe
(
1
)
})
return
}
let
page
;
let
page
;
function
getData
(
key
=
''
)
{
function
getData
(
key
=
''
)
{
return
new
Promise
(
async
(
resolve
,
reject
)
=>
{
return
new
Promise
(
async
(
resolve
,
reject
)
=>
{
...
...
pages/API/get-app-authorize-setting/get-app-authorize-setting.test.js
浏览文件 @
cb6378e0
const
PAGE_PATH
=
'
/pages/API/get-app-authorize-setting/get-app-authorize-setting
'
const
PAGE_PATH
=
'
/pages/API/get-app-authorize-setting/get-app-authorize-setting
'
describe
(
'
ExtApi-GetAppAuthorizeSetting
'
,
()
=>
{
describe
(
'
ExtApi-GetAppAuthorizeSetting
'
,
()
=>
{
if
(
process
.
env
.
uniTestPlatformInfo
.
indexOf
(
'
web
'
)
>
-
1
)
{
it
(
'
dummyTest
'
,
()
=>
{
expect
(
1
).
toBe
(
1
)
})
return
}
let
page
;
let
page
;
let
res
;
let
res
;
...
...
pages/API/get-battery-info/get-battery-info.test.js
浏览文件 @
cb6378e0
const
PAGE_PATH
=
'
/pages/API/get-battery-info/get-battery-info
'
const
PAGE_PATH
=
'
/pages/API/get-battery-info/get-battery-info
'
describe
(
'
ExtApi-GetBatteryInfo
'
,
()
=>
{
describe
(
'
ExtApi-GetBatteryInfo
'
,
()
=>
{
if
(
process
.
env
.
uniTestPlatformInfo
.
indexOf
(
'
web
'
)
>
-
1
)
{
it
(
'
dummyTest
'
,
()
=>
{
expect
(
1
).
toBe
(
1
)
})
return
}
let
page
;
let
page
;
let
res
;
let
res
;
...
...
pages/API/get-element-by-id/get-element-by-id-multiple-root-node.test.js
浏览文件 @
cb6378e0
...
@@ -3,6 +3,12 @@ const PAGE_PATH =
...
@@ -3,6 +3,12 @@ const PAGE_PATH =
let
page
;
let
page
;
describe
(
"
getElementByIdForMultipleRootNode
"
,
()
=>
{
describe
(
"
getElementByIdForMultipleRootNode
"
,
()
=>
{
if
(
process
.
env
.
uniTestPlatformInfo
.
indexOf
(
'
web
'
)
>
-
1
)
{
it
(
'
dummyTest
'
,
()
=>
{
expect
(
1
).
toBe
(
1
)
})
return
}
beforeAll
(
async
()
=>
{
beforeAll
(
async
()
=>
{
page
=
await
program
.
reLaunch
(
PAGE_PATH
);
page
=
await
program
.
reLaunch
(
PAGE_PATH
);
await
page
.
waitFor
(
'
view
'
);
await
page
.
waitFor
(
'
view
'
);
...
...
pages/API/get-element-by-id/get-element-by-id.test.js
浏览文件 @
cb6378e0
...
@@ -2,6 +2,12 @@ const PAGE_PATH = "/pages/API/get-element-by-id/get-element-by-id";
...
@@ -2,6 +2,12 @@ const PAGE_PATH = "/pages/API/get-element-by-id/get-element-by-id";
let
page
;
let
page
;
describe
(
"
getElementById
"
,
()
=>
{
describe
(
"
getElementById
"
,
()
=>
{
if
(
process
.
env
.
uniTestPlatformInfo
.
indexOf
(
'
web
'
)
>
-
1
)
{
it
(
'
dummyTest
'
,
()
=>
{
expect
(
1
).
toBe
(
1
)
})
return
}
beforeAll
(
async
()
=>
{
beforeAll
(
async
()
=>
{
page
=
await
program
.
reLaunch
(
PAGE_PATH
);
page
=
await
program
.
reLaunch
(
PAGE_PATH
);
await
page
.
waitFor
(
'
view
'
);
await
page
.
waitFor
(
'
view
'
);
...
...
pages/API/get-file-system-manager/get-file-system-manager.test.js
浏览文件 @
cb6378e0
...
@@ -2,7 +2,12 @@ const PAGE_PATH = '/pages/API/get-file-system-manager/get-file-system-manager'
...
@@ -2,7 +2,12 @@ const PAGE_PATH = '/pages/API/get-file-system-manager/get-file-system-manager'
describe
(
'
ExtApi-FileManagerTest
'
,
()
=>
{
describe
(
'
ExtApi-FileManagerTest
'
,
()
=>
{
if
(
process
.
env
.
uniTestPlatformInfo
.
indexOf
(
'
web
'
)
>
-
1
)
{
it
(
'
dummyTest
'
,
()
=>
{
expect
(
1
).
toBe
(
1
)
})
return
}
let
page
;
let
page
;
function
getData
(
key
=
''
)
{
function
getData
(
key
=
''
)
{
return
new
Promise
(
async
(
resolve
,
reject
)
=>
{
return
new
Promise
(
async
(
resolve
,
reject
)
=>
{
...
...
pages/API/unicloud-database/unicloud-database.uvue
浏览文件 @
cb6378e0
...
@@ -61,7 +61,7 @@
...
@@ -61,7 +61,7 @@
uni.showToast({
uni.showToast({
title: content
title: content
})
})
console.
error
(title, content)
console.
log
(title, content)
}
}
},
},
async dbAdd() : Promise<void> {
async dbAdd() : Promise<void> {
...
...
pages/component/list-view/list-view-multiplex.test.js
浏览文件 @
cb6378e0
describe
(
'
component-native-list-view
'
,
()
=>
{
describe
(
'
component-native-list-view
'
,
()
=>
{
if
(
process
.
env
.
uniTestPlatformInfo
.
startsWith
(
'
android
'
))
{
if
(
process
.
env
.
uniTestPlatformInfo
.
startsWith
(
'
web
'
))
{
it
(
'
dummyTest
'
,
async
()
=>
{
expect
(
1
).
toBe
(
1
)
})
return
}
let
page
let
page
beforeAll
(
async
()
=>
{
beforeAll
(
async
()
=>
{
//打开list-view-multiplex测试页
//打开list-view-multiplex测试页
...
@@ -13,10 +18,4 @@ describe('component-native-list-view', () => {
...
@@ -13,10 +18,4 @@ describe('component-native-list-view', () => {
await
page
.
waitFor
(
400
)
await
page
.
waitFor
(
400
)
await
page
.
callMethod
(
'
listViewScrollByY
'
,
100
)
await
page
.
callMethod
(
'
listViewScrollByY
'
,
100
)
})
})
}
else
{
// TODO: web 端暂不支持
it
(
'
web
'
,
async
()
=>
{
expect
(
1
).
toBe
(
1
)
})
}
})
})
pages/component/list-view/list-view.test.js
浏览文件 @
cb6378e0
describe
(
'
component-native-list-view
'
,
()
=>
{
describe
(
'
component-native-list-view
'
,
()
=>
{
if
(
process
.
env
.
uniTestPlatformInfo
.
startsWith
(
'
android
'
))
{
if
(
process
.
env
.
uniTestPlatformInfo
.
startsWith
(
'
web
'
))
{
it
(
'
dummyTest
'
,
async
()
=>
{
expect
(
1
).
toBe
(
1
)
})
return
}
let
page
let
page
beforeAll
(
async
()
=>
{
beforeAll
(
async
()
=>
{
//打开list-view测试页
//打开list-view测试页
...
@@ -76,10 +81,4 @@ describe('component-native-list-view', () => {
...
@@ -76,10 +81,4 @@ describe('component-native-list-view', () => {
await
page
.
callMethod
(
'
item_change_size_enum
'
,
0
)
await
page
.
callMethod
(
'
item_change_size_enum
'
,
0
)
expect
(
scrollLeft
-
1080
).
toBeGreaterThanOrEqual
(
0
)
expect
(
scrollLeft
-
1080
).
toBeGreaterThanOrEqual
(
0
)
})
})
}
else
{
// TODO: web 端暂不支持
it
(
'
web
'
,
async
()
=>
{
expect
(
1
).
toBe
(
1
)
})
}
})
})
pages/pages.test.js
浏览文件 @
cb6378e0
...
@@ -106,16 +106,16 @@ const pages = [
...
@@ -106,16 +106,16 @@ const pages = [
// template
// template
// '/pages/template/calendar/calendar', // 动态内容
// '/pages/template/calendar/calendar', // 动态内容
'
/pages/template/custom-refresher/custom-refresher
'
,
//
'/pages/template/custom-refresher/custom-refresher',
'
/pages/template/custom-tab-bar/custom-tab-bar
'
,
//
'/pages/template/custom-tab-bar/custom-tab-bar',
// '/pages/template/drop-card/drop-card',
// '/pages/template/drop-card/drop-card',
'
/pages/template/half-screen/half-screen
'
,
//
'/pages/template/half-screen/half-screen',
// '/pages/template/list-news/list-news', // 网络资源加载,单独测试例截图
// '/pages/template/list-news/list-news', // 网络资源加载,单独测试例截图
// '/pages/template/long-list/long-list', // 动态内容
// '/pages/template/long-list/long-list', // 动态内容
'
/pages/template/navbar-lite/navbar-lite
'
,
//
'/pages/template/navbar-lite/navbar-lite',
'
/pages/template/pull-zoom-image/pull-zoom-image
'
,
//
'/pages/template/pull-zoom-image/pull-zoom-image',
'
/pages/template/scroll-fold-nav/scroll-fold-nav
'
,
//
'/pages/template/scroll-fold-nav/scroll-fold-nav',
'
/pages/template/scroll-sticky/scroll-sticky
'
,
//
'/pages/template/scroll-sticky/scroll-sticky',
// '/pages/template/swiper-list/swiper-list',
// '/pages/template/swiper-list/swiper-list',
// '/pages/template/swiper-list2/swiper-list2',
// '/pages/template/swiper-list2/swiper-list2',
// '/pages/template/swiper-vertical-video/swiper-vertical-video'
// '/pages/template/swiper-vertical-video/swiper-vertical-video'
...
@@ -132,6 +132,13 @@ if (process.env.uniTestPlatformInfo.startsWith('android')) {
...
@@ -132,6 +132,13 @@ if (process.env.uniTestPlatformInfo.startsWith('android')) {
'
/pages/template/swiper-list/swiper-list
'
,
'
/pages/template/swiper-list/swiper-list
'
,
'
/pages/template/swiper-list2/swiper-list2
'
,
'
/pages/template/swiper-list2/swiper-list2
'
,
'
/pages/API/element-draw/element-draw
'
,
'
/pages/API/element-draw/element-draw
'
,
'
/pages/template/navbar-lite/navbar-lite
'
,
'
/pages/template/pull-zoom-image/pull-zoom-image
'
,
'
/pages/template/scroll-fold-nav/scroll-fold-nav
'
,
'
/pages/template/scroll-sticky/scroll-sticky
'
,
'
/pages/template/custom-refresher/custom-refresher
'
,
'
/pages/template/custom-tab-bar/custom-tab-bar
'
,
'
/pages/template/half-screen/half-screen
'
,
)
)
}
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录