Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
DCloud
uni-starter
提交
9601656e
U
uni-starter
项目概览
DCloud
/
uni-starter
通知
4742
Star
231
Fork
211
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
6
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
uni-starter
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
6
Issue
6
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
9601656e
编写于
4月 27, 2025
作者:
Anne_LXM
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
test 调整测试例
上级
80430261
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
16 addition
and
22 deletion
+16
-22
pages/ucenter/settings/settings.test.js
pages/ucenter/settings/settings.test.js
+5
-8
pages/ucenter/ucenter.test.js
pages/ucenter/ucenter.test.js
+5
-7
uni_modules/uni-id-pages/pages/userinfo/userinfo.test.js
uni_modules/uni-id-pages/pages/userinfo/userinfo.test.js
+6
-7
未找到文件。
pages/ucenter/settings/settings.test.js
浏览文件 @
9601656e
...
...
@@ -12,14 +12,11 @@ describe('settings', () => {
beforeAll
(
async
()
=>
{
page
=
await
program
.
navigateTo
(
'
/pages/ucenter/settings/settings
'
)
await
page
.
waitFor
(
'
view
'
)
hasLogin
=
await
page
.
callMethod
(
'
hasLoginTest
'
)
if
(
!
hasLogin
)
{
console
.
log
(
"
未登录测试失败
"
)
it
(
'
未登录
'
,
async
()
=>
{
expect
(
1
).
toBe
(
1
)
})
return
}
hasLogin
=
await
page
.
callMethod
(
'
hasLoginTest
'
)
if
(
!
hasLogin
)
{
console
.
log
(
"
未登录测试失败
"
)
return
}
})
it
(
'
settings
'
,
async
()
=>
{
if
(
process
.
env
.
UNI_PLATFORM
.
startsWith
(
"
app
"
))
{
...
...
pages/ucenter/ucenter.test.js
浏览文件 @
9601656e
...
...
@@ -11,13 +11,11 @@ describe('ucenter', () => {
beforeAll
(
async
()
=>
{
page
=
await
program
.
switchTab
(
'
/pages/ucenter/ucenter
'
)
await
page
.
waitFor
(
'
view
'
)
hasLogin
=
await
page
.
callMethod
(
'
hasLoginTest
'
)
if
(
!
hasLogin
)
{
console
.
log
(
'
未登录测试失败
'
)
it
(
'
未登录
'
,
async
()
=>
{
expect
(
1
).
toBe
(
1
)
})
}
hasLogin
=
await
page
.
callMethod
(
'
hasLoginTest
'
)
if
(
!
hasLogin
)
{
console
.
log
(
'
未登录测试失败
'
)
return
}
})
it
(
'
宫格
'
,
async
()
=>
{
expect
.
assertions
(
1
);
...
...
uni_modules/uni-id-pages/pages/userinfo/userinfo.test.js
浏览文件 @
9601656e
...
...
@@ -12,14 +12,13 @@ describe('userinfo', () => {
beforeAll
(
async
()
=>
{
page
=
await
program
.
navigateTo
(
PAGE_PATH
)
await
page
.
waitFor
(
"
view
"
)
userInfo
=
await
page
.
callMethod
(
'
userInfoTest
'
)
if
(
!
userInfo
.
_id
)
{
console
.
log
(
"
未登录测试失败
"
,
userInfo
)
it
(
'
未登录
'
,
async
()
=>
{
expect
(
1
).
toBe
(
1
)
})
userInfo
=
await
page
.
callMethod
(
'
userInfoTest
'
)
console
.
log
(
"
userInfo
"
,
userInfo
)
if
(
!
userInfo
.
_id
)
{
console
.
log
(
"
未登录测试失败
"
)
return
}
});
});
it
(
"
昵称
"
,
async
()
=>
{
const
nickname
=
"
数字天堂DCloud
"
+
Math
.
round
(
Math
.
random
()
*
10
);
await
page
.
waitFor
(
300
)
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录