fix(editor): « − » press follows Delete, discriminating focus tests
This commit is contained in:
1 parent
03e85a7c67
commit
62b400e876
9 files changed
+131
-45
No files matched your search
@@ -226,6 +226,8 @@ for (const width of WIDTHS) {
|
||||
})
|
||||
const [, moved] = await shownPoints(page)
|
||||
expect(moved).not.toEqual(SQUARE[1])
|
||||
// The finger's commit leaves the focus on the dragged vertex, never on the page body.
|
||||
await expect(page.locator('[data-vertex="1"]:focus')).toHaveCount(1)
|
||||
// The chosen vertex shows its « − » bubble: finger-sized too.
|
||||
await expect(
|
||||
page.getByRole('button', { name: /^Retirer le sommet/ }),
|
||||
@@ -242,6 +244,9 @@ for (const width of WIDTHS) {
|
||||
dict['editor.annotations.message.moved.point'],
|
||||
)
|
||||
expect(await shownNumber(page, 'cx')).toBeLessThan(750)
|
||||
await expect(
|
||||
page.getByTestId('point-handle').and(page.locator(':focus')),
|
||||
).toHaveCount(1)
|
||||
// Zoomed in, the handles keep their CSS px size.
|
||||
await pinchOut(cdp, await clientOf(page, EMPTY.x, EMPTY.y))
|
||||
expect((await framing(page)).scale).toBeGreaterThan(1)
|
||||
|
||||
Reference in new issue
Block a user