Skip to content

feat: #253 new app-bar (existing app switcher) (#261) #123

feat: #253 new app-bar (existing app switcher) (#261)

feat: #253 new app-bar (existing app switcher) (#261) #123

Workflow file for this run

name: Visual Regression Tests
on:
push:
branches: [main]
# Allow updating snapshots during manual runs
workflow_call:
inputs:
update-snapshots:
description: 'Update snapshots?'
type: boolean
# Allow updating snapshots during automatic runs
workflow_dispatch:
inputs:
update-snapshots:
description: 'Update snapshots?'
type: boolean
env:
NPM_TOKEN: ${{secrets.NPM_TOKEN}}
CI: true
jobs:
test:
timeout-minutes: 60
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set Node
uses: actions/setup-node@v3
with:
node-version: '18.x'
- name: Install dependencies
run: yarn
- name: Install Playwright Browsers
run: yarn playwright install --with-deps
- name: Build Storybook
run: |
yarn build:storybook
- name: Set up cache
id: cache
uses: actions/cache@v4
with:
key: cache/${{github.repository}}/${{github.ref}}
restore-keys: cache/${{github.repository}}/refs/heads/main
path: .visual-test/**
- name: Initialize snapshots
if: ${{steps.cache.outputs.cache-hit != 'true' || inputs.update-snapshots == true}}
run: npx playwright test --update-snapshots --reporter html
- name: Run Playwright tests
run: yarn playwright test
- uses: actions/upload-artifact@v4
if: always()
with:
name: playwright-report
path: .visual-test/spec/results/
retention-days: 30
overwrite: true