Skip to content

Commit

Permalink
chore: Adjust maxFailures to accomodate for retries
Browse files Browse the repository at this point in the history
  • Loading branch information
flozia committed Sep 27, 2024
1 parent 06be398 commit c7bb0ce
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions playwright.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ const webServerConfig = {

const shouldStartWebServer = process.env.E2E_TEST_ENV === "local"

const maxRetries = 1;

export default defineConfig({
testDir: 'src/e2e/specs',
/* Maximum time one test can run for. */
Expand Down Expand Up @@ -51,10 +53,10 @@ export default defineConfig({
forbidOnly: !!process.env.CI,

/* Limit the number of failures */
maxFailures: 1,
maxFailures: maxRetries * 2,

/* Retry on CI only */
retries: process.env.CI ? 1 : 0,
retries: process.env.CI ? maxRetries : 0,

/* Use a custom percentage of available wokers in CI and use default locally. */
workers: process.env.CI ? "75%" : undefined,
Expand Down

0 comments on commit c7bb0ce

Please sign in to comment.