提交 f12b08cd 编写于 作者: Y yurj26

fix: 测试例兼容web

上级 f192cfb1
......@@ -17,12 +17,16 @@ describe('PickerView.uvue', () => {
await page.callMethod('setValue')
await page.waitFor(1000)
expect(await el.property('value')).toEqual([0, 0, 0])
if (process.env.UNI_PLATFORM === 'app-android') {
expect(await getData('result')).toEqual([0, 0, 0])
}
await page.callMethod('setValue1')
await page.waitFor(1000)
expect(await el.property('value')).toEqual([10, 10, 10])
if (process.env.UNI_PLATFORM === 'app-android') {
expect(await getData('result')).toEqual([10, 10, 10])
}
})
it('length', async () => {
......
......@@ -57,9 +57,6 @@
}
},
methods: {
clickView() {
},
bindChange(e : PickerViewChangeEvent) {
const val = e.detail.value
this.result = val
......
......@@ -23,14 +23,18 @@ describe('Progress.uvue', () => {
expect(await p2.property('percent')).toEqual(60)
const p3 = await page.$('.p3')
expect(await p3.property('percent')).toEqual(80)
if (process.env.UNI_PLATFORM === 'app-android') {
expect(await getData('curPercent')).toEqual(20)
}
await page.callMethod('clearProgress')
await page.waitFor(1000)
expect(await p.property('percent')).toEqual(0)
expect(await p1.property('percent')).toEqual(0)
expect(await p2.property('percent')).toEqual(0)
expect(await p3.property('percent')).toEqual(0)
if (process.env.UNI_PLATFORM === 'app-android') {
expect(await getData('curPercent')).toEqual(0)
}
})
it('length', async () => {
const elements = await page.$$('.progress')
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册