diff --git a/pages/component/scroll-view/scroll-view.test.js b/pages/component/scroll-view/scroll-view.test.js index 130281b47037598d5f9b921f865fdd2ae9fa09eb..09d8bce58ec23c92828054814018edbfd3541846 100644 --- a/pages/component/scroll-view/scroll-view.test.js +++ b/pages/component/scroll-view/scroll-view.test.js @@ -22,7 +22,7 @@ describe('component-native-scroll-view', () => { await page.waitFor(1000) // 设置top 是否触发scroll 事件 const topScrollDetail = await page.data('scrollDetailTest') - // console.log('topScrollDetail:', topScrollDetail) + console.log('topScrollDetail:', topScrollDetail) expect(topScrollDetail.scrollLeft).toBe(0) // Android 差异scrollTop:99.809525 expect([100, 99.809525]).toContain(topScrollDetail.scrollTop); @@ -36,10 +36,10 @@ describe('component-native-scroll-view', () => { it('Event scroll-horizontal',async()=>{ // 横向滚动 await page.setData({scrollLeft:220}) - await page.waitFor(600) + await page.waitFor(1000) //设置left 是否触发scroll 事件 const leftScrollDetail = await page.data('scrollDetailTest') - // console.log('leftScrollDetail:', leftScrollDetail) + console.log('leftScrollDetail:', leftScrollDetail) // Android 差异scrollLeft:219.80952 expect([220, 219.80952]).toContain(leftScrollDetail.scrollLeft); expect(leftScrollDetail.scrollTop).toBe(0) @@ -69,7 +69,7 @@ describe('component-native-scroll-view', () => { if(!process.env.UNI_UTS_PLATFORM.startsWith('web')){ it('Event scrollend-滚动结束时触发仅App端支持',async()=>{ const endDetail = await page.data('scrollEndDetailTest') - // console.log('scrollEndDetailTest:', endDetail) + console.log('scrollEndDetailTest:', endDetail) expect(endDetail.scrollLeft).toBe(0) expect(endDetail.scrollTop).toBe(0) expect(endDetail.deltaY).toBe(0)