Description
EDIT: Update description
With Template Activation some @wordpress/e2e-test-utils-playwright stopped working as they used to, mainly saveSiteEditorEntities in packages/e2e-test-utils-playwright/src/editor/site-editor.ts. Save flow has changed and will be updated so final changes should include whatever #71811 ends up with
This is old description but visitSiteEditor can be easily addressed by either providing wp_id returned for custom created template or replacing wp_template with wp_registered_template.
With Template Activation some @wordpress/e2e-test-utils-playwright stopped working as they used to, mainly visitSiteEditor in packages/e2e-test-utils-playwright/src/admin/visit-site-editor.ts no longer works when passing postType: wp_template, postId: <<template_slug>> resulting in /wp-admin/site-editor.php?postId=twentytwentyfour%2F%2Fsingle-product&postType=wp_template&canvas=edit and no content:
Step-by-step reproduction instructions
In your Playwright test use visitSiteEditor util to visit template in editor:
Used to be:
await visitSiteEditor( {
postId: <<TEMPLATE_SLUG>>,
postType: 'wp_template',
canvas: 'edit',
} );
now with template slug being represented by postId it cannot be always known upfront.
Screenshots, screen recording, code snippet
No response
Environment info
Please confirm that you have searched existing issues in the repo.
Please confirm that you have tested with all plugins deactivated except Gutenberg.
Please confirm which theme type you used for testing.
Description
EDIT: Update description
With Template Activation some
@wordpress/e2e-test-utils-playwrightstopped working as they used to, mainlysaveSiteEditorEntitiesinpackages/e2e-test-utils-playwright/src/editor/site-editor.ts. Save flow has changed and will be updated so final changes should include whatever #71811 ends up withThis is old description but
visitSiteEditorcan be easily addressed by either providingwp_idreturned for custom created template or replacingwp_templatewithwp_registered_template.With Template Activation some
@wordpress/e2e-test-utils-playwrightstopped working as they used to, mainlyvisitSiteEditorinpackages/e2e-test-utils-playwright/src/admin/visit-site-editor.tsno longer works when passingpostType: wp_template, postId: <<template_slug>>resulting in/wp-admin/site-editor.php?postId=twentytwentyfour%2F%2Fsingle-product&postType=wp_template&canvas=editand no content:Step-by-step reproduction instructions
In your Playwright test use
visitSiteEditorutil to visit template in editor:Used to be:
now with template slug being represented by
postIdit cannot be always known upfront.Screenshots, screen recording, code snippet
No response
Environment info
Please confirm that you have searched existing issues in the repo.
Please confirm that you have tested with all plugins deactivated except Gutenberg.
Please confirm which theme type you used for testing.