Skip to content

Commit

Permalink
E2e: use canvas helper for iframed content
Browse files Browse the repository at this point in the history
  • Loading branch information
ellatrix committed Aug 5, 2024
1 parent 438a17f commit 8d02104
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion test/e2e/specs/editor/plugins/wp-editor-meta-box.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ test.describe( 'WP Editor Meta Boxes', () => {
await admin.createNewPost();

// Add title to enable valid non-empty post save.
await page
await editor.canvas
.locator( 'role=textbox[name="Add title"i]' )
.type( 'Hello Meta' );

Expand Down
7 changes: 3 additions & 4 deletions test/e2e/specs/editor/various/publish-button.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,12 @@ test.describe( 'Post publish button', () => {
admin,
page,
requestUtils,
editor,
} ) => {
await requestUtils.activatePlugin( 'gutenberg-test-plugin-meta-box' );
await admin.createNewPost();
await page
.getByRole( 'textbox', {
name: 'Add title',
} )
await editor.canvas
.getByRole( 'textbox', { name: 'Add title' } )
.fill( 'Test post' );

const topBar = page.getByRole( 'region', { name: 'Editor top bar' } );
Expand Down

0 comments on commit 8d02104

Please sign in to comment.