Skip to content

Workflow file for this run

name: E2E
on: [deployment_status]
jobs:
e2e:
# only runs this job on successful deploy
if: github.event.deployment_status.state == 'success'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
# fetch all commits so we can find the branch
fetch-depth: 0
- uses: actions/setup-node@v3
with:
node-version: 18.x
cache: "yarn"
- name: Install dependencies
run: yarn install --immutable
- name: Install Playwright Browsers
run: npx playwright install --with-deps chromium
- name: Run Playwright tests
run: yarn e2e -- --grep-invert @noci
env:
E2E_BASE_URL: ${{ github.event.deployment_status.target_url }}
PERCY_TOKEN: ${{ secrets.PERCY_TOKEN }}
- name: Upload E2E artifacts to job
uses: actions/upload-artifact@v3
if: failure()
with:
name: e2e-screenshots
path: |
e2e-screenshots
playwright-report
# https://docs.github.com/en/actions/reference/context-and-expression-syntax-for-github-actions#job-status-check-functions