提交 21b4a905 编写于 作者: study夏羽's avatar study夏羽

fix:修改昵称问题

上级 16eddae4
......@@ -18,10 +18,10 @@ module.exports = {
},
"app-plus": {
"android": {
"id": "",
"executablePath": "D:/HX/alpha-3.1.3/HBuilderX/plugins/launcher/base/android_base.apk"
"id": "d3a144fa",
"executablePath": "D:\\HX\\alpha-3.1.3\\HBuilderX\\plugins\\launcher\\base\\android_base.apk"
},
"version": "",
"version": "D:\\HX\\alpha-3.1.3\\HBuilderX\\plugins\\launcher\\base\\version.txt",
"ios": {
"id": "",
"executablePath": ""
......
......@@ -4,7 +4,7 @@
describe('pages/list/search/search.vue', () => {
let page
beforeAll(async () => {
page = await program.navigateTo('/pages/list/search/search')
page = await program.redirectTo('/pages/list/search/search')
await page.waitFor(500)
})
it('搜索发现-显示-影藏', async () => {
......
......@@ -16,23 +16,12 @@ describe('pages/ucenter/login-page/pwd-login/pwd-login.vue', () => {
expect((await program.currentPage()).path).toBe(
'pages/ucenter/login-page/register/register')
console.log(await program.currentPage(),"111111111");
// await page.waitFor(500)
await page.waitFor(500)
// 执行 navigateBack 验证是否返回navigateTo
// expect((await program.navigateBack()).path).toBe(
// 'pages/ucenter/login-page/pwd-login/pwd-login')
})
it('跳转到忘记密码页', async () => {
const resPwd = await page.callMethod('toRetrievePwd')
expect((await program.navigateBack()).path).toBe(
'pages/ucenter/login-page/pwd-login/pwd-login')
await page.waitFor(300)
expect((await program.currentPage()).path).toBe(
'pages/ucenter/login-page/pwd-retrieve/pwd-retrieve')
console.log(await program.currentPage(),"222222");
// await page.waitFor(500)
// 执行 navigateBack 验证是否返回
// expect((await program.navigateBack()).path).toBe(
// 'pages/ucenter/login-page/pwd-login/pwd-login')
console.log(await program.currentPage(),"22222222222");
})
it('用户名密码登录', async () => {
......
......@@ -159,9 +159,6 @@
uni.navigateTo({
url: '/pages/ucenter/login-page/register/register'
})
// uni.redirectTo({
// url: '/pages/ucenter/login-page/register/register'
// })
}
}
}
......
......@@ -41,7 +41,6 @@ describe('pages/ucenter/login-page/register/register.vue', () => {
await page.waitFor(300)
return resRegister
})
console.log("getUid:---------- ",getUid.msg);
if (getUid.uid) {
expect(getUid.msg).toBe("注册成功");
......
......@@ -55,6 +55,10 @@ describe('pages/ucenter/userinfo/bind-mobile/bind-mobile.vue', () => {
break;
}
}
await program.switchTab('/pages/ucenter/ucenter')
console.log(await program.currentPage(),"last-------------------");
})
});
\ No newline at end of file
......@@ -9,15 +9,14 @@ describe('pages/ucenter/userinfo/userinfo.vue', () => {
})
/* it('设置昵称', async () => {
it('设置昵称', async () => {
const getTokenRes = await page.waitFor(async()=>{
return await page.data('uniToken')
})
console.log("getTokenRes: ",getTokenRes);
console.log("getTokenRes:---------------------- ",getTokenRes);
var name = "数字天堂DCloud" + Math.round(Math.random()*10);
console.log("name: ",name);
console.log(await page.data('uniToken'),"---------------------");
if(getTokenRes){
const nicknameRes = await page.callMethod("setNickname",name)
await page.waitFor(300)
......@@ -25,15 +24,13 @@ describe('pages/ucenter/userinfo/userinfo.vue', () => {
expect(nicknameRes.updated).toBe(1)
}
}) */
})
it('绑定手机号', async () => {
console.log(await page.data('uniToken'),"-------------------------");
await page.callMethod('bindMobileBySmsCode')
await page.waitFor(300)
console.log((await program.currentPage()).path);
expect((await program.currentPage()).path).toBe('pages/ucenter/userinfo/bind-mobile/bind-mobile')
await page.waitFor(300)
// expect((await program.currentPage()).path).toBe('pages/ucenter/userinfo/bind-mobile/bind-mobile')
// await page.waitFor(300)
expect((await program.navigateBack()).path).toBe('pages/ucenter/userinfo/userinfo')
})
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册