Skip to content

Commit 7ecd2a2

Browse files
authored
test(e2e): Replace deprecated 'clickCount' property with 'count' (#12778)
This fixes double clicks when using WebDriver BiDi. See puppeteer/puppeteer#13550
1 parent 4650715 commit 7ecd2a2

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

packages/vue/__tests__/e2e/todomvc.spec.ts

+4-4
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ describe('e2e: todomvc', () => {
139139
// editing triggered by blur
140140
await click('.filters li:nth-child(1) a')
141141
await timeout(1)
142-
await click('.todo:nth-child(1) label', { clickCount: 2 })
142+
await click('.todo:nth-child(1) label', { count: 2 })
143143
expect(await count('.todo.editing')).toBe(1)
144144
expect(await isFocused('.todo:nth-child(1) .edit')).toBe(true)
145145
await clearValue('.todo:nth-child(1) .edit')
@@ -149,21 +149,21 @@ describe('e2e: todomvc', () => {
149149
expect(await text('.todo:nth-child(1) label')).toBe('edited!')
150150

151151
// editing triggered by enter
152-
await click('.todo label', { clickCount: 2 })
152+
await click('.todo label', { count: 2 })
153153
await enterValue('.todo:nth-child(1) .edit', 'edited again!')
154154
expect(await count('.todo.editing')).toBe(0)
155155
expect(await text('.todo:nth-child(1) label')).toBe('edited again!')
156156

157157
// cancel
158-
await click('.todo label', { clickCount: 2 })
158+
await click('.todo label', { count: 2 })
159159
await clearValue('.todo:nth-child(1) .edit')
160160
await page().type('.todo:nth-child(1) .edit', 'edited!')
161161
await page().keyboard.press('Escape')
162162
expect(await count('.todo.editing')).toBe(0)
163163
expect(await text('.todo:nth-child(1) label')).toBe('edited again!')
164164

165165
// empty value should remove
166-
await click('.todo label', { clickCount: 2 })
166+
await click('.todo label', { count: 2 })
167167
await enterValue('.todo:nth-child(1) .edit', ' ')
168168
expect(await count('.todo')).toBe(3)
169169

packages/vue/__tests__/e2e/tree.spec.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ describe('e2e: tree', () => {
8888
expect(await isVisible('#demo ul')).toBe(true)
8989
expect(await text('#demo li div span')).toContain('[-]')
9090

91-
await click('#demo ul > .item div', { clickCount: 2 })
91+
await click('#demo ul > .item div', { count: 2 })
9292
expect(await count('.item')).toBe(15)
9393
expect(await count('.item > ul')).toBe(5)
9494
expect(await text('#demo ul > .item:nth-child(1)')).toContain('[-]')

0 commit comments

Comments
 (0)