π Playwright #262
This file contains 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: π Playwright | |
on: | |
deployment_status: | |
jobs: | |
playwright: | |
name: π Playwright | |
if: github.event.deployment_status.state == 'success' | |
runs-on: ubuntu-latest | |
timeout-minutes: 60 | |
env: | |
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }} | |
TURBO_TEAM: ${{ secrets.TURBO_TEAM }} | |
steps: | |
- name: β¬οΈ Checkout repo | |
uses: actions/checkout@v4 | |
- name: π§ͺ Copy test env vars | |
run: cp apps/web/.env.example apps/web/.env | |
- name: π¦ Setup pnpm | |
uses: pnpm/action-setup@v2 | |
with: | |
version: 8 | |
- name: π Setup node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version-file: package.json | |
cache: pnpm | |
- name: π₯ Download deps | |
run: pnpm install --prefer-offline --frozen-lockfile | |
- name: π₯ Install Playwright Browsers | |
run: pnpm dlx playwright install --with-deps | |
- name: π Playwright tests | |
run: pnpm run test:e2e | |
env: | |
BASE_URL: ${{ github.event.deployment_status.target_url }} | |
- name: π Upload report | |
uses: actions/upload-artifact@v4 | |
if: always() | |
with: | |
name: playwright-report | |
path: packages/playwright/playwright-report/ | |
retention-days: 30 |