提交 311a58b5 编写于 作者: H hdx

picker-view.test: 调整自动化测试写法

上级 13dc8383
...@@ -16,14 +16,18 @@ describe('PickerView.uvue', () => { ...@@ -16,14 +16,18 @@ describe('PickerView.uvue', () => {
const el = await page.$('.picker-view') const el = await page.$('.picker-view')
await page.callMethod('setValue') await page.callMethod('setValue')
await page.waitFor(1000) await page.waitFor(1000)
expect(await el.property('value')).toEqual([0, 0, 0]) const newValue1 = await el.property('value')
// TODO
expect(newValue1.toString()).toEqual('0,0,0')
if (process.env.UNI_PLATFORM === 'app-android') { if (process.env.UNI_PLATFORM === 'app-android') {
expect(await getData('result')).toEqual([0, 0, 0]) expect(await getData('result')).toEqual([0, 0, 0])
} }
await page.callMethod('setValue1') await page.callMethod('setValue1')
await page.waitFor(1000) await page.waitFor(1000)
expect(await el.property('value')).toEqual([10, 10, 10]) const newValue2 = await el.property('value')
// TODO
expect(newValue2.toString()).toEqual('10,10,10')
if (process.env.UNI_PLATFORM === 'app-android') { if (process.env.UNI_PLATFORM === 'app-android') {
expect(await getData('result')).toEqual([10, 10, 10]) expect(await getData('result')).toEqual([10, 10, 10])
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册