Skip to content

Commit fc079a5

Browse files
feat: add new Playwright tests workflow for end-to-end testing
1 parent d176183 commit fc079a5

File tree

1 file changed

+39
-0
lines changed

1 file changed

+39
-0
lines changed

.github/workflows/new-e2e.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Playwright Tests New
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
preview_url:
7+
description: "Deployment preview URL"
8+
required: true
9+
type: string
10+
11+
permissions:
12+
contents: read
13+
issues: write
14+
15+
jobs:
16+
run-e2es:
17+
timeout-minutes: 35
18+
runs-on: ubuntu-latest
19+
name: Run E2E tests
20+
steps:
21+
- name: Checkout repository
22+
uses: actions/checkout@v4
23+
24+
- name: Install dependencies
25+
run: npm ci && npx playwright install --with-deps
26+
27+
- name: Run E2E tests
28+
env:
29+
NEXT_PUBLIC_URL: ${{ inputs.preview_url }}
30+
run: |
31+
npx playwright test || echo "Tests failed" > test-failure.log
32+
33+
- name: Upload Playwright Report
34+
if: always()
35+
uses: actions/upload-artifact@v4
36+
with:
37+
name: reports
38+
path: packages/dashboard/playwright/reports/
39+
retention-days: 7

0 commit comments

Comments
 (0)