Skip to content
This repository has been archived by the owner on Feb 23, 2024. It is now read-only.

Commit

Permalink
Fix failing E2E test: fails to transform into blocks
Browse files Browse the repository at this point in the history
  • Loading branch information
tarhi-saad authored and Aljullu committed Nov 7, 2023
1 parent 1a1e09f commit f6f6a89
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions tests/e2e/utils/editor/editor-utils.page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -295,21 +295,14 @@ export class EditorUtils {
}

async transformIntoBlocks() {
const isNotTransformedIntoBlocks = await this.page
.frameLocator( 'iframe[name="editor-canvas"]' )
const isNotTransformedIntoBlocks = await this.editor.canvas
.getByRole( 'button', { name: 'Transform into blocks' } )
.count();

if ( isNotTransformedIntoBlocks ) {
await this.page
.frameLocator( 'iframe[name="editor-canvas"]' )
.getByRole( 'group' )
.click();
await this.page
.frameLocator( 'iframe[name="editor-canvas"]' )
await this.editor.canvas
.getByRole( 'button', { name: 'Transform into blocks' } )
.click();

// save changes
await this.saveSiteEditorEntities();
}
Expand Down

0 comments on commit f6f6a89

Please sign in to comment.