提交 ec65f06d 编写于 作者: Anne_LXM's avatar Anne_LXM

更新showToast测试例

上级 9f015f35
......@@ -72,4 +72,19 @@ describe('API-toast', () => {
await toScreenshot('toast-duration-end')
})
if(process.env.uniTestPlatformInfo.startsWith('web')){
return
}
it("position-toast-test", async () => {
const positions = await page.$$('.radio-position')
for (let i = 0; i < positions.length; i++) {
await positions[i].tap()
const positionsText = await positions[i].attribute('value')
await page.callMethod('toast2Tap')
await page.waitFor(100);
await toScreenshot(`position-${positionsText}`)
}
})
});
......@@ -69,8 +69,8 @@
intervalSelect: 1500,
position_current:0,
position_enum: [
{ "value": "top", "name": "top: 居上显示" },
{ "value": "center", "name": "center: 居中显示" },
{ "value": "top", "name": "top: 居上显示(Android 暂不支持)" },
{ "value": "center", "name": "center: 居中显示(Android 暂不支持)" },
{ "value": "bottom", "name": "bottom: 居底显示" },
] as PositionItemType[],
icon_current:0,
......@@ -148,7 +148,7 @@
image: this.imageSelect? "/static/uni.png" : null ,
mask: this.maskSelect,
success: (res) => {
console.log('success:',res)
// console.log('success:',res)
this.exeRet = "success:" + JSON.stringify(res)
},
fail: (res) => {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册