-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix flaky Site Editor pages e2e test #52283
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, tests well for me and changes make sense 👍
Thanks for fixing this one so quickly, @Mamaduka 🚀
@@ -78,7 +78,7 @@ test.describe( 'Pages', () => { | |||
).toBeVisible(); | |||
|
|||
// Switch to template editing focus. | |||
await page.getByRole( 'button', { name: 'Settings' } ).click(); | |||
await editor.openDocumentSettingsSidebar(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's unrelated to the fix, but it's better to use the util to avoid accidentally closing the 'Settings' sidebar if it is open.
Thanks for testing, @tyxla! |
Size Change: 0 B Total Size: 1.42 MB ℹ️ View Unchanged
|
Thanks @Mamaduka |
What?
I noticed this test failing on the trunk due to the broad scope locator - https://github.com/WordPress/gutenberg/actions/runs/5453941422/jobs/9923411345.
Why?
It turns out we're always rendering the "Navigation" region in the site editor, and it also can have a "Back" button.
How?
A better-scoped "Back" button locator.
Testing Instructions