Backstop Sanity Tests #2
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: Backstop Sanity Tests | |
on: | |
workflow_dispatch: | |
workflow_call: | |
permissions: | |
actions: write | |
contents: write | |
pull-requests: write | |
env: | |
NODE_VERSION: 20 | |
jobs: | |
sanity-puppeteer: | |
name: 🤪 Puppeteer | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 1 | |
ref: ${{ github.event.pull_request.head.sha || github.ref }} | |
- name: ⬢ Setup Node & Cache | |
uses: actions/setup-node@v4 | |
with: | |
cache: "npm" | |
cache-dependency-path: package-lock.json | |
- name: ↧ Install | |
run: npm ci | |
- name: "𓋏 Run `npm run sanity-test`" | |
run: | | |
npm run sanity-test | |
sanity-playwright: | |
name: 🤪 Playwright | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 1 | |
ref: ${{ github.event.pull_request.head.sha || github.ref }} | |
- name: ⬢ Setup Node & Cache | |
uses: actions/setup-node@v4 | |
with: | |
cache: "npm" | |
cache-dependency-path: package-lock.json | |
- name: ↧ Install | |
run: npm ci | |
- name: "🎭 Run `npm run sanity-test-playwright`" | |
run: | | |
npx playwright install --with-deps | |
npm run sanity-test-playwright |