Skip to content

Commit 2d3ad2e

Browse files
committed
increase timeout for fix webkit tests
1 parent c08e784 commit 2d3ad2e

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

react-example/e2e/inapp-e2e.spec.ts

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -156,8 +156,10 @@ test.describe('In-App Messaging - E2E (Real API)', () => {
156156
.first();
157157
if (await closeButton.isVisible({ timeout: 2000 }).catch(() => false)) {
158158
await closeButton.click();
159-
// Wait for iframe to be removed
160-
await expect(page.locator('iframe#iterable-iframe')).not.toBeAttached();
159+
// Wait for iframe to be removed (longer timeout for WebKit in CI)
160+
await expect(page.locator('iframe#iterable-iframe')).not.toBeAttached({
161+
timeout: 10000
162+
});
161163
}
162164

163165
await inAppPage.pauseButton.click();
@@ -183,8 +185,8 @@ test.describe('In-App Messaging - E2E (Real API)', () => {
183185
.first();
184186
if (await closeButton.isVisible({ timeout: 2000 }).catch(() => false)) {
185187
await closeButton.click();
186-
// Wait for iframe to be removed
187-
await expect(iframe).not.toBeAttached();
188+
// Wait for iframe to be removed (longer timeout for WebKit in CI)
189+
await expect(iframe).not.toBeAttached({ timeout: 10000 });
188190
}
189191
}
190192

react-example/e2e/utils/message-helpers.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,12 +67,10 @@ export class MessageHelpers {
6767

6868
/**
6969
* Wait for iframe to be visible and return it
70-
*
71-
* Uses web-first assertion instead of hard timeout
7270
*/
7371
static async waitForMessageIframe(page: Page): Promise<FrameLocator> {
7472
const iframe = MessageHelpers.getMessageIframe(page);
75-
await expect(iframe.locator('body')).toBeVisible({ timeout: 5000 });
73+
await expect(iframe.locator('body')).toBeVisible({ timeout: 10000 });
7674
return iframe;
7775
}
7876

0 commit comments

Comments
 (0)