Skip to content

Commit 15c989d

Browse files
committed
fix(ci): restore e2e job with proper Playwright browser install steps
1 parent a965c0c commit 15c989d

1 file changed

Lines changed: 60 additions & 6 deletions

File tree

.github/workflows/test.yml

Lines changed: 60 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,63 @@ jobs:
9797
retention-days: 7
9898
path: packages/*/.artifacts/unit/junit.xml
9999

100-
# e2e job disabled — Playwright browser tests hang indefinitely in CI
101-
# (30+ min every run, no progress). This is an upstream issue, not fork-specific.
102-
# Re-enable when upstream fixes the Playwright CI hang.
103-
# e2e:
104-
# name: e2e (${{ matrix.settings.name }})
105-
# ... (see git history for full config)
100+
e2e:
101+
name: e2e (linux)
102+
runs-on: ubuntu-latest
103+
env:
104+
PLAYWRIGHT_BROWSERS_PATH: ${{ github.workspace }}/.playwright-browsers
105+
defaults:
106+
run:
107+
shell: bash
108+
steps:
109+
- name: Checkout repository
110+
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
111+
with:
112+
token: ${{ secrets.GITHUB_TOKEN }}
113+
114+
- name: Setup Node
115+
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
116+
with:
117+
node-version: "24"
118+
119+
- name: Setup Bun
120+
uses: ./.github/actions/setup-bun
121+
122+
- name: Read Playwright version
123+
id: playwright-version
124+
run: |
125+
version=$(node -e 'console.log(require("./package.json").workspaces.catalog["@playwright/test"])')
126+
echo "version=$version" >> "$GITHUB_OUTPUT"
127+
128+
- name: Cache Playwright browsers
129+
id: playwright-cache
130+
uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
131+
with:
132+
path: ${{ github.workspace }}/.playwright-browsers
133+
key: ${{ runner.os }}-${{ runner.arch }}-playwright-${{ steps.playwright-version.outputs.version }}-chromium
134+
135+
- name: Install Playwright system dependencies
136+
working-directory: packages/app
137+
run: bunx playwright install-deps chromium
138+
139+
- name: Install Playwright browsers
140+
if: steps.playwright-cache.outputs.cache-hit != 'true'
141+
working-directory: packages/app
142+
run: bunx playwright install chromium
143+
144+
- name: Run app e2e tests
145+
run: bun --cwd packages/app test:e2e:local
146+
env:
147+
CI: true
148+
timeout-minutes: 30
149+
150+
- name: Upload Playwright artifacts
151+
if: always()
152+
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
153+
with:
154+
name: playwright-linux-${{ github.run_attempt }}
155+
if-no-files-found: ignore
156+
retention-days: 7
157+
path: |
158+
packages/app/e2e/test-results
159+
packages/app/e2e/playwright-report

0 commit comments

Comments
 (0)