From 0441524abcf27b183e2467445dd8623d7282d6a3 Mon Sep 17 00:00:00 2001 From: lizhongyi Date: Mon, 1 Apr 2024 18:11:33 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4list-view=E6=B5=8B=E8=AF=95?= =?UTF-8?q?=E4=BE=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/component/list-view/list-view.test.js | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/pages/component/list-view/list-view.test.js b/pages/component/list-view/list-view.test.js index e8711f6f..68454aef 100644 --- a/pages/component/list-view/list-view.test.js +++ b/pages/component/list-view/list-view.test.js @@ -6,15 +6,6 @@ describe('component-native-list-view', () => { await page.waitFor(600) }) - //检测竖向可滚动区域 - it('check_scroll_height', async () => { - await page.callMethod('change_scroll_y_boolean', true) - await page.callMethod('change_scroll_x_boolean', false) - await page.waitFor(600) - const value = await page.callMethod('check_scroll_height') - expect(value).toBe(true) - }) - //检测竖向scrolltop属性赋值 it('check_scroll_top', async () => { await page.callMethod('confirm_scroll_top_input', 600) @@ -44,10 +35,20 @@ describe('component-native-list-view', () => { if (process.env.uniTestPlatformInfo.indexOf('web') > -1) { return } - if(process.env.uniTestPlatformInfo.startsWith('IOS_SIMULATOR')) { + + + if(process.env.uniTestPlatformInfo.toLowerCase().startsWith('ios')) { return } + //检测竖向可滚动区域 + it('check_scroll_height', async () => { + await page.callMethod('change_scroll_y_boolean', true) + await page.callMethod('change_scroll_x_boolean', false) + await page.waitFor(600) + const value = await page.callMethod('check_scroll_height') + expect(value).toBe(true) + }) //检测横向可滚动区域 备注:iOS不支持list-view横向滚动 it('check_scroll_width', async () => { -- GitLab