Skip to content

E2E

E2E #56

Workflow file for this run

name: E2E
on:
pull_request:
branches: [master, main]
paths:
- 'src/**'
- 'e2e/**'
- 'playwright.config.ts'
- 'package.json'
- 'package-lock.json'
- '.github/workflows/e2e.yml'
schedule:
- cron: '0 5 * * *' # 05:00 UTC nightly (after perf at 04:00)
workflow_dispatch:
jobs:
e2e:
runs-on: ubuntu-latest
timeout-minutes: 20
env:
E2E_MODE: 'true'
# Required by Next build; values are placeholders since the analyze
# route is mocked and Prisma is only touched on admin paths.
ANTHROPIC_API_KEY: 'sk-e2e-placeholder'
DATABASE_URL: 'postgresql://e2e:e2e@localhost:5432/e2e'
NEXT_TELEMETRY_DISABLED: '1'
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: 'npm'
- name: Install dependencies
run: npm ci
- name: Cache Playwright browsers
uses: actions/cache@v4
with:
path: ~/.cache/ms-playwright
key: playwright-${{ runner.os }}-${{ hashFiles('package-lock.json') }}
- name: Install Playwright browsers
run: npx playwright install --with-deps chromium
- name: Run Playwright tests
run: npm run e2e
- name: Upload report
if: failure()
uses: actions/upload-artifact@v4
with:
name: playwright-report
path: playwright-report/
retention-days: 14