Cache Playwright browsers in CI
Playwright browser download (25s) is now cached by pnpm-lock hash. On cache hit, only install system deps (fast). On miss, full install. Current E2E timings (first run): - Postgres container: 19s - BRouter JAR: cached - Berlin segment: 6s (will be cached next run) - Playwright install: 25s → cached after first run - BRouter startup: 9s - Tests: 27s Expected after caching: ~60s total (down from ~107s). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
f0afa8a4a7
commit
f2f5c6a83e
1 changed files with 14 additions and 1 deletions
15
.github/workflows/ci.yml
vendored
15
.github/workflows/ci.yml
vendored
|
|
@ -139,7 +139,20 @@ jobs:
|
|||
env:
|
||||
BROUTER_URL: http://localhost:17777
|
||||
|
||||
- run: pnpm exec playwright install --with-deps chromium
|
||||
- name: Cache Playwright browsers
|
||||
id: playwright-cache
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: ~/.cache/ms-playwright
|
||||
key: playwright-${{ hashFiles('pnpm-lock.yaml') }}
|
||||
|
||||
- name: Install Playwright
|
||||
if: steps.playwright-cache.outputs.cache-hit != 'true'
|
||||
run: pnpm exec playwright install --with-deps chromium
|
||||
|
||||
- name: Install Playwright deps only
|
||||
if: steps.playwright-cache.outputs.cache-hit == 'true'
|
||||
run: pnpm exec playwright install-deps chromium
|
||||
|
||||
- name: Run E2E tests
|
||||
run: pnpm test:e2e
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue