clean copy #326
Workflow file for this run
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: PWA Tests | |
| permissions: | |
| contents: read | |
| on: | |
| pull_request: | |
| branches: [main] | |
| # Service worker / offline behavior is a function of the frontend build and the | |
| # PWA test harness — no backend involved, so only run when those change. | |
| paths: | |
| - 'frontend/**' | |
| - 'e2e-pwa/**' | |
| - 'playwright.pwa.config.ts' | |
| - 'package.json' | |
| - 'package-lock.json' | |
| - '.github/workflows/pwa.yml' | |
| concurrency: | |
| group: pwa-${{ github.head_ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| pwa: | |
| name: Service Worker / Offline E2E | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4 | |
| with: | |
| node-version: '22' | |
| cache: 'npm' | |
| cache-dependency-path: | | |
| package-lock.json | |
| frontend/package-lock.json | |
| - name: Install root dependencies | |
| run: npm ci | |
| - name: Install frontend dependencies | |
| run: npm ci | |
| working-directory: frontend | |
| # webkit is the closest iOS Safari engine proxy; --with-deps pulls the OS | |
| # libraries it needs on Ubuntu. The config builds the frontend + serves preview. | |
| - name: Install Playwright browsers | |
| run: npx playwright install --with-deps chromium webkit | |
| - name: Run PWA tests | |
| run: npm run test:pwa | |
| - name: Upload Playwright report | |
| uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 | |
| if: ${{ !cancelled() }} | |
| with: | |
| name: pwa-playwright-report | |
| path: playwright-report/ | |
| retention-days: 14 |