Skip to content

Commit 2d23579

Browse files
committed
fix: e2e test failing
1 parent 52cb97d commit 2d23579

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

tests/e2e/specs/loop.spec.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import { test, expect } from '@wordpress/e2e-test-utils-playwright';
66
test.describe('Feedzy Loop', () => {
77
const FEED_URL =
88
'https://s3.amazonaws.com/verti-utils/sample-feed-import.xml';
9+
const POST_TITLE = `Feedzy Loop Test ${Math.floor(Math.random() * 1000)}`;
910

1011
test('add Feedzy Loop Block', async ({ editor, page }) => {
1112
await page.goto('/wp-admin/post-new.php');
@@ -21,7 +22,7 @@ test.describe('Feedzy Loop', () => {
2122
}
2223

2324
await page.getByLabel('Add title').click();
24-
await page.keyboard.type('Feedzy Loop Test');
25+
await page.keyboard.type(POST_TITLE);
2526

2627
await page.getByLabel('Toggle block inserter').click();
2728

@@ -39,6 +40,8 @@ test.describe('Feedzy Loop', () => {
3940
await page.getByRole('button', { name: 'Save', exact: true }).click();
4041
await page.waitForTimeout(1000);
4142

43+
await page.getByLabel('Display curated RSS content').click();
44+
4245
await page
4346
.getByRole('button', { name: 'Publish', exact: true })
4447
.click();
@@ -58,7 +61,7 @@ test.describe('Feedzy Loop', () => {
5861

5962
const postTitle = await page.locator('a.row-title').first();
6063
await postTitle.hover();
61-
await page.getByLabel('View “Feedzy Loop Test”').click();
64+
await page.getByLabel('View “' + POST_TITLE + '”').click();
6265

6366
await page.waitForTimeout(5000);
6467

0 commit comments

Comments
 (0)