Skip to content

Commit c112346

Browse files
committed
feat: Delete first top level menu item and focus reaches nav block and inserter to be visible
1 parent df05527 commit c112346

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

test/e2e/specs/editor/blocks/navigation.spec.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -586,6 +586,17 @@ test.describe( 'Navigation block', () => {
586586
*/
587587
await pageUtils.pressKeys( 'access+z' );
588588
await navigation.checkLabelFocus( 'Cat' );
589+
590+
/**
591+
* Test: Deleting with no more siblings should focus the navigation block again
592+
*/
593+
await pageUtils.pressKeys( 'access+z' );
594+
await expect( navigation.getNavBlock() ).toBeFocused();
595+
// Wait until the nav block inserter is visible before we continue.
596+
await expect( navigation.getNavBlockInserter() ).toBeVisible();
597+
// Now the appender should be visible and reachable with an arrow down
598+
await pageUtils.pressKeys( 'ArrowDown' );
599+
await expect( navigation.getNavBlockInserter() ).toBeFocused();
589600
} );
590601
} );
591602

0 commit comments

Comments
 (0)