From 85590a4dfa6de45ea3014af1e2e008cc079f845a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E7=A3=8A?= <1633537611@qq.com> Date: Wed, 1 Nov 2023 18:44:21 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=AD=98=E5=9C=A8=E5=85=89?= =?UTF-8?q?=E6=A0=87=E5=8F=AF=E8=83=BD=E5=AF=BC=E8=87=B4=E8=87=AA=E5=8A=A8?= =?UTF-8?q?=E5=8C=96=E5=A4=B1=E8=B4=A5=E7=9A=84bug=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/component/input/input.test.js | 48 ++++++++++++++--------------- 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/pages/component/input/input.test.js b/pages/component/input/input.test.js index d419ddcc..fe7fd79e 100644 --- a/pages/component/input/input.test.js +++ b/pages/component/input/input.test.js @@ -15,30 +15,30 @@ describe('component-native-input', () => { // expect(image).toMatchImageSnapshot() // }) // 测试焦点及键盘弹起 - // it('focus', async () => { - // const input = await page.$('.uni-input-focus'); - // expect(await input.property('focus')).toBe(true) - // expect(await page.data("inputFocusKeyBoardChangeValue")).toBe(true) - // await page.setData({ - // focus: false, - // }) - // expect(await input.property('focus')).toBe(false) - // await page.waitFor(1000) - // expect(await page.data("inputFocusKeyBoardChangeValue")).toBe(false) - // await page.setData({ - // focus: true, - // }) - // expect(await input.property('focus')).toBe(true) - // await page.waitFor(1000) - // expect(await page.data("inputFocusKeyBoardChangeValue")).toBe(true) - // await page.setData({ - // focus: false, - // }) - // expect(await input.property('focus')).toBe(false) - // await page.waitFor(1000) - // expect(await page.data("inputFocusKeyBoardChangeValue")).toBe(false) - // await page.waitFor(1000) - // }); + it('focus', async () => { + const input = await page.$('.uni-input-focus'); + expect(await input.property('focus')).toBe("true") + // expect(await page.data("inputFocusKeyBoardChangeValue")).toBe(true) + await page.setData({ + focus: false, + }) + expect(await input.property('focus')).toBe("false") + // await page.waitFor(1000) + // expect(await page.data("inputFocusKeyBoardChangeValue")).toBe(false) + // await page.setData({ + // focus: true, + // }) + // expect(await input.property('focus')).toBe(true) + // await page.waitFor(1000) + // expect(await page.data("inputFocusKeyBoardChangeValue")).toBe(true) + // await page.setData({ + // focus: false, + // }) + // expect(await input.property('focus')).toBe(false) + // await page.waitFor(1000) + // expect(await page.data("inputFocusKeyBoardChangeValue")).toBe(false) + // await page.waitFor(1000) + }); // 测试修改value属性 it("value", async () => { -- GitLab