test(core): rewrite some flaky assertions (#5287)
This commit is contained in:
@@ -13,10 +13,11 @@ test('Duplicate page should work', async ({ page }) => {
|
||||
await waitForEditorLoad(page);
|
||||
await clickNewPageButton(page);
|
||||
const title = getBlockSuiteEditorTitle(page);
|
||||
await title.pressSequentially('test');
|
||||
await expect(title).toBeVisible();
|
||||
await title.fill('test');
|
||||
await clickPageMoreActions(page);
|
||||
const duplicateButton = page.getByTestId('editor-option-menu-duplicate');
|
||||
await duplicateButton.click({ delay: 100 });
|
||||
await duplicateButton.click();
|
||||
const title2 = getBlockSuiteEditorTitle(page);
|
||||
await expect(title2).toHaveText('test(1)', { timeout: 1000 });
|
||||
await expect(title2).toHaveText('test(1)');
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user