diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8f5fa97..3bd3f25 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -39,3 +39,41 @@ jobs: - name: Run accessibility smoke tests run: pnpm run test:a11y + + smoke-test: + name: Smoke Test + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Setup pnpm + uses: pnpm/action-setup@v4 + with: + version: 10.32.1 + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: "20" + cache: "pnpm" + + - name: Install dependencies + run: pnpm install --frozen-lockfile + + - name: Cache Playwright browsers + uses: actions/cache@v4 + id: playwright-cache + with: + path: ~/.cache/ms-playwright + key: ${{ runner.os }}-playwright-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-playwright- + + - name: Install Playwright browsers + if: steps.playwright-cache.outputs.cache-hit != 'true' + run: pnpm exec playwright install --with-deps + + - name: Run Playwright tests + run: pnpm run test:e2e diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 4603f36..8b82fc0 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -105,6 +105,7 @@ you may need these additional environment variables. Add them to your local `.en - [ ] Keep the PR focused on one concern. - [ ] Run `pnpm lint` and fix reported issues. - [ ] Run `pnpm test:unit` for unit coverage. +- [ ] Run `pnpm test:e2e` to ensure Playwright smoke tests pass. - [ ] Run `pnpm build` for the TypeScript/Vite production build. - [ ] Include screenshots or a short screen recording for visible UI changes. - [ ] Mention any env vars, migrations, or manual QA steps reviewers need.