-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Navigation: Re-enable navigation block e2e tests #29543
Conversation
packages/block-editor/src/components/block-list/use-block-props/index.js
Outdated
Show resolved
Hide resolved
Size Change: 0 B Total Size: 1.4 MB ℹ️ View Unchanged
|
There are some tests already: The nav block is currently plugin only so the tests are in the experiments folder. They're currently skipped (since #27018), would be great to re-enable them if it's the right time. |
The REST endpoint mocking in those tests is a little bit difficult to work with, that's something I've also been dealing with in the navigation editor too (https://github.com/WordPress/gutenberg/blob/trunk/packages/e2e-tests/specs/experiments/navigation-editor.test.js). Not sure if it'd be sensible to abandon the use of REST mocking and just create the needed page/menus before each test and remove them after. The downside would be considerable time added to tests. |
Thanks @talldan I'll update the existing E2Es instead. I'm seeing some instability with the navigation block (it can crash based on click input in an empty menu) so we can re-enable E2E tests when that's fixed. It'll be too flakey for the full suite otherwise. I'll try to fix that in this PR unless someone else spots it first.
🤔 It might be worth creating a test plugin/theme for this if we'd like to test editing a non-trivial menu. |
I'd like to get #29391 fixed first before we re-enable E2E tests. I'm setting this back to draft for now. |
1cf75aa
to
c0f7ad0
Compare
…n placeholder UI from dropdown to buttons
b922fca
to
6cd8ef1
Compare
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.
Sounds good to me!
Thanks for the review @ellatrix 💖 |
Fixes #27588 and re-enables navigation tests
It looks like the existing mocks still work, so we can maybe look into making test navigation data easier to work with in a follow up.
run.mp4
Testing Instructions
Verify that tests make sense and run well