test: add mutex to clipboard copy & paste operation to reduce flaky (#11884)

This commit is contained in:
Brooooooklyn
2025-04-22 11:02:29 +00:00
parent 4fd468c46f
commit bfd3c64615
10 changed files with 32 additions and 28 deletions
+1 -2
View File
@@ -60,8 +60,7 @@ export async function type(page: Page, content: string, delay = 50) {
}
export const createLinkedPage = async (page: Page, pageName?: string) => {
// fixme: workaround for @ popover not showing up when editor is not ready
await page.waitForTimeout(500);
await waitForEditorLoad(page);
await page.keyboard.type('@', { delay: 50 });
const linkedPagePopover = page.locator('.linked-doc-popover');
await expect(linkedPagePopover).toBeVisible();