Skip to content

AI-native design editor. Open-source Figma alternative.

test(app): stabilize final interaction coverage

Danila Poyarkov2348b1c972fc
diff --git a/tests/e2e/context-menu/basic.spec.ts b/tests/e2e/context-menu/basic.spec.ts
index 5fd92ca33..83d588b85 100644
--- a/tests/e2e/context-menu/basic.spec.ts
+++ b/tests/e2e/context-menu/basic.spec.ts
@@ -229,13 +229,15 @@ test('outline stroke is disabled for fill-only shapes', async () => {
})
test('Copy/Paste as submenu exists', async () => {
+ await editor.canvas.clearCanvas()
+ await editor.canvas.drawRect(200, 200, 120, 80)
+ await editor.canvas.waitForRender()
await rightClickShape(250, 230)
const submenuTrigger = contextItem('context-copy-paste-as')
await expect(submenuTrigger).toBeVisible()
- await submenuTrigger.hover()
- await editor.page.waitForTimeout(300)
+ await submenuTrigger.click({ force: true })
await expect(contextItem('context-copy-as-svg')).toBeVisible()
await expect(contextItem('context-copy-as-jsx')).toBeVisible()
diff --git a/tests/e2e/fixtures.ts b/tests/e2e/fixtures.ts
index 8e84e84e0..545a06e69 100644
--- a/tests/e2e/fixtures.ts
+++ b/tests/e2e/fixtures.ts
@@ -16,7 +16,7 @@ export function useEditorSetup(url = '/') {
})
test.afterAll(async () => {
- await page.close()
+ if (page) await page.close()
})
return {
diff --git a/tests/e2e/text/formatting.spec.ts-snapshots/typography-panel-openpencil-darwin.png b/tests/e2e/text/formatting.spec.ts-snapshots/typography-panel-openpencil-darwin.png
index 918967779..ad8a13ccb 100644
Binary files a/tests/e2e/text/formatting.spec.ts-snapshots/typography-panel-openpencil-darwin.png and b/tests/e2e/text/formatting.spec.ts-snapshots/typography-panel-openpencil-darwin.png differ