From e04ea76263f7a7e093c593392add4b506526a58c Mon Sep 17 00:00:00 2001 From: Andrei Draganescu Date: Tue, 23 Aug 2022 11:56:21 +0300 Subject: [PATCH] unskips focus test and adds await to a click event --- packages/e2e-tests/specs/editor/blocks/navigation.test.js | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/packages/e2e-tests/specs/editor/blocks/navigation.test.js b/packages/e2e-tests/specs/editor/blocks/navigation.test.js index f95b806495957..befea0ee89561 100644 --- a/packages/e2e-tests/specs/editor/blocks/navigation.test.js +++ b/packages/e2e-tests/specs/editor/blocks/navigation.test.js @@ -1681,10 +1681,7 @@ Expected mock function not to be called but it was called with: ["POST", "http:/ ); } ); - // Skip reason: running it in interactive works but selecting and - // checking for focus consistently fails in the test. - // eslint-disable-next-line jest/no-disabled-tests - it.skip( 'should always focus select menu button after item selection', async () => { + it( 'should always focus select menu button after item selection', async () => { // Create some navigation menus to work with. await createNavigationMenu( { title: 'First navigation', @@ -1712,7 +1709,7 @@ Expected mock function not to be called but it was called with: ["POST", "http:/ const theOption = await page.waitForXPath( "//button[@aria-checked='false'][contains(., 'First navigation')]" ); - theOption.click(); + await theOption.click(); // Once the options are closed, does select menu button receive focus? const selectMenuDropdown2 = await page.$(