refactor(ci): replace ci.yml with focused e2e.yml #1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: E2E | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| e2e: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 10 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: pnpm/action-setup@v4 | |
| with: | |
| version: 10 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '22' | |
| cache: 'pnpm' | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Install Playwright browsers | |
| run: pnpm exec playwright install --with-deps chromium | |
| - name: Build application | |
| run: pnpm build | |
| env: | |
| NEXT_PUBLIC_SUPABASE_URL: https://mock.supabase.co | |
| NEXT_PUBLIC_SUPABASE_ANON_KEY: mock-anon-key | |
| NEXT_PUBLIC_ENABLE_MSW_MOCK: 'true' | |
| APP_ENV: test | |
| - name: Run E2E tests | |
| run: pnpm test:e2e | |
| env: | |
| NEXT_PUBLIC_SUPABASE_URL: https://mock.supabase.co | |
| NEXT_PUBLIC_SUPABASE_ANON_KEY: mock-anon-key | |
| NEXT_PUBLIC_ENABLE_MSW_MOCK: 'true' | |
| APP_ENV: test | |
| - name: Upload test artifacts | |
| uses: actions/upload-artifact@v4 | |
| if: failure() | |
| with: | |
| name: playwright-report | |
| path: playwright-report/ | |
| retention-days: 7 |