From ea0003b08d88a994ead8dda2cfce0dce873a3d3c Mon Sep 17 00:00:00 2001 From: Nirmal Kumar R Date: Wed, 20 Nov 2024 20:55:19 +0530 Subject: [PATCH] Use await for editor toBeVisible() --- tests/e2e/markdown-editor.test.e2e.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/e2e/markdown-editor.test.e2e.ts b/tests/e2e/markdown-editor.test.e2e.ts index e88371a34a..b85975ff2c 100644 --- a/tests/e2e/markdown-editor.test.e2e.ts +++ b/tests/e2e/markdown-editor.test.e2e.ts @@ -26,7 +26,7 @@ test('Markdown image preview behaviour', async ({browser}, workerInfo) => { // This yields the monaco editor const editor = page.getByRole('presentation').nth(0); - expect(editor).toBeVisible(); + await expect(editor).toBeVisible(); await editor.click(); // Clear all the content await page.keyboard.press('ControlOrMeta+KeyA');