Skip to content

Commit

Permalink
Added screenshots on failure option
Browse files Browse the repository at this point in the history
  • Loading branch information
CandelR committed Jan 14, 2025
1 parent 76ba52e commit 0a86c59
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
6 changes: 6 additions & 0 deletions .github/workflows/playwright.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,9 @@ jobs:
name: playwright-report
path: playwright-report/
retention-days: 30
- uses: actions/upload-artifact@v4
if: always()
with:
name: playwright-artifacts
path: test-results/
retention-days: 30
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@
"vercel:install": "yarn run add:npmrc && yarn install",
"test:unit": "vitest run test/unit && vitest run src/ ",
"test:coverage": "vitest run --coverage",
"test:playwright": "yarn playwright test --headed",
"test:playwright": "yarn playwright test",
"test:chromium": "yarn playwright test --project=chromium",
"test:firefox": "yarn playwright test --project=firefox",
"test:safari": "yarn playwright test --project=webkit",
Expand Down
2 changes: 2 additions & 0 deletions playwright.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,12 @@ export default defineConfig({
use: {
/* Base URL to use in actions like `await page.goto('/')`. */
baseURL: 'https://drive.internxt.com/login',
screenshot: 'only-on-failure',

/* Collect trace when retrying the failed test. See https://playwright.dev/docs/trace-viewer */
trace: 'on-first-retry',
},
outputDir: 'test-results',

/* Configure projects for major browsers */
projects: [
Expand Down

0 comments on commit 0a86c59

Please sign in to comment.