Experiment: add first basic user post types e2e tests and update taxonomy tests#77998
Conversation
|
Size Change: 0 B Total Size: 7.95 MB ℹ️ View Unchanged
|
Mamaduka
left a comment
There was a problem hiding this comment.
A pass by review for now.
- Visit utils can be inlined, IMO, there's not much gain in single-line utils.
- It's good practice to e2e test UI and the results the user will see, instead of testing REST API responses. If there are no success/failure notices, then UI should be updated first.
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
|
Flaky tests detected in 07bb387. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/25442844862
|
I briefly considered that and was eh.. it's okay. Since you thought about it too, I'll update 😄
I get your point and I thought about that in taxonomies e2e tests (which are the base for these tests). My thinking for these basic tests was to test the UI for create/edit and activate/deactivate and verify through REST that the registration happened as expected. In my mind verifying via REST was the cheapest assertion that the type was actually registered, because having a properly registered taxonomy/post type would ensure any UI (menu items, etc..) to exist, which live in different flows. That said. I'll update that too. |
Sure, but what happens when REST API functions as expected, but the UI contract regresses or breaks? We'll get false positives in the tests. |
tyxla
left a comment
There was a problem hiding this comment.
This is looking good from my perspective.
I've added a few nits and suggestions, nothing critical/blocking.
…nomy tests (#77998) Co-authored-by: ntsekouras <ntsekouras@git.wordpress.org> Co-authored-by: Mamaduka <mamaduka@git.wordpress.org> Co-authored-by: tyxla <tyxla@git.wordpress.org>
What?
Part of: #77600
This PR adds some first basic e2e tests for the user post types experiment, mirroring the ones for taxonomies.