Skip to content

Commit 09f7a2d

Browse files
committed
fix toBeVisible checks
1 parent 8a15284 commit 09f7a2d

2 files changed

Lines changed: 8 additions & 6 deletions

File tree

playwright/e2e/button/button-filters.spec.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,9 @@ test.describe( 'Button Block', () => {
9898
} ) => {
9999
// Alignment should be set
100100
await editor.clickBlockToolbarButton( 'Change button alignment' );
101-
await page
102-
.locator( 'button.is-active:text("Align text center")' )
103-
.isVisible();
101+
await expect(
102+
await page.locator( 'button.is-active:text("Align text center")' )
103+
).toBeVisible();
104104

105105
// Text should be set
106106
await expect(

playwright/e2e/column/column-filters.spec.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -168,9 +168,11 @@ test.describe( 'Column Block - Filters', () => {
168168
await editor.clickBlockToolbarButton(
169169
'Change vertical alignment of content'
170170
);
171-
await page
172-
.locator( 'button.is-active:text("Align content bottom")' )
173-
.isVisible();
171+
await expect(
172+
await page.locator(
173+
'button.is-active:text("Align content bottom")'
174+
)
175+
).toBeVisible();
174176

175177
// Check if attributes are set correctly
176178
expect( await editor.getEditedPostContent() ).toMatchSnapshot(

0 commit comments

Comments
 (0)