Skip to content

Commit

Permalink
Fix flaky Site Editor pages e2e test (#52283)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mamaduka authored Jul 4, 2023
1 parent 5ba7484 commit f59138d
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions test/e2e/specs/site-editor/pages.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ test.describe( 'Pages', () => {
).toBeVisible();

// Switch to template editing focus.
await page.getByRole( 'button', { name: 'Settings' } ).click();
await editor.openDocumentSettingsSidebar();
await page
.getByRole( 'region', { name: 'Editor settings' } )
.getByRole( 'button', { name: 'Edit template' } )
Expand All @@ -102,7 +102,10 @@ test.describe( 'Pages', () => {
.fill( 'New Site Title' );

// Go back to page editing focus.
await page.getByRole( 'button', { name: 'Back', exact: true } ).click();
await page
.getByRole( 'region', { name: 'Editor top bar' } )
.getByRole( 'button', { name: 'Back' } )
.click();

// Site Title and Page entities should have been modified.
await page.getByRole( 'button', { name: 'Save', exact: true } ).click();
Expand Down

0 comments on commit f59138d

Please sign in to comment.