提交 f6435d5a 编写于 作者: H hdx

slider100: 增加自动化测试

上级 38736a20
const PAGE_PATH = '/pages/component/slider-100/slider-100'
describe('slider', () => {
let page
beforeAll(async () => {
page = await program.reLaunch(PAGE_PATH)
await page.waitFor(500)
})
it('value', async () => {
const sliderValue = 80
await page.setData({
sliderValue: sliderValue,
})
await page.waitFor(100)
// TODO 暂时仅获取第一个
const slider1 = await page.$('.slider')
expect(await slider1.property('value')).toBe(sliderValue)
// const slider100 = await page.$$('.slider')
// for (let i = 0; i < slider100.length; i++) {
// const slider = slider100[i];
// expect(await slider.property('value')).toBe(sliderValue)
// }
})
})
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册