Deflake e2e tests (#316)

This commit is contained in:
Will Chen
2025-06-02 22:48:03 -07:00
committed by GitHub
parent 5802c39825
commit 81345153fc
3 changed files with 3 additions and 3 deletions

View File

@@ -99,7 +99,7 @@ class PageObject {
async snapshotPreview() {
const iframe = this.getPreviewIframeElement();
await expect(iframe.contentFrame().locator("body")).toMatchAriaSnapshot({
timeout: 15_000,
timeout: 30_000,
});
}

View File

@@ -15,6 +15,6 @@ test("create next.js app", async ({ po }) => {
await po.clickRestart();
// This can be pretty slow because it's waiting for the app to build.
await expect(po.getPreviewIframeElement()).toBeVisible({ timeout: 25_000 });
await expect(po.getPreviewIframeElement()).toBeVisible({ timeout: 50_000 });
await po.snapshotPreview();
});

View File

@@ -5,7 +5,7 @@ const config: PlaywrightTestConfig = {
workers: 1,
retries: process.env.CI ? 1 : 0,
// maxFailures: 1,
timeout: process.env.CI ? 60_000 : 30_000,
timeout: process.env.CI ? 75_000 : 30_000,
// Use a custom snapshot path template because Playwright's default
// is platform-specific which isn't necessary for Dyad e2e tests
// which should be platform agnostic (we don't do screenshots; only textual diffs).