diff --git a/pages/component/scroll-view/scroll-view-refresher.test.js b/pages/component/scroll-view/scroll-view-refresher.test.js index cc050d6656557cb028c9bcad31e440bd21d2d87c..27e8473e70df2355bac08427bf5f1754d65fb6b9 100644 --- a/pages/component/scroll-view/scroll-view-refresher.test.js +++ b/pages/component/scroll-view/scroll-view-refresher.test.js @@ -1,19 +1,24 @@ -// uni-app自动化测试教程: uni-app自动化测试教程: https://uniapp.dcloud.net.cn/worktile/auto/hbuilderx-extension/ - -describe('test title', () => { - - let page; - beforeAll(async () => { - page = await program.reLaunch('/pages/component/scroll-view/scroll-view-refresher'); - await page.waitFor(300); - }); - - - it('check_refresher', async () => { - await page.setData({ - refresherTriggered: true - }) - await page.waitFor(2000); - expect(await page.data('refresherrefresh')).toBe(true) - }); +// uni-app自动化测试教程: uni-app自动化测试教程: https://uniapp.dcloud.net.cn/worktile/auto/hbuilderx-extension/ + +describe('test title', () => { + if (process.env.uniTestPlatformInfo.startsWith('android')) { + let page; + beforeAll(async () => { + page = await program.reLaunch('/pages/component/scroll-view/scroll-view-refresher'); + await page.waitFor(300); + }); + + + it('check_refresher', async () => { + await page.setData({ + refresherTriggered: true + }) + await page.waitFor(2000); + expect(await page.data('refresherrefresh')).toBe(true) + }); + } else { + it('other platform', () => { + expect(1).toBe(1) + }) + } });