Skip to content

VRT

VRT #66

Workflow file for this run

name: VRT
on:
deployment_status:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: false
jobs:
screenshots:
if: github.event_name == 'deployment_status' && github.event.deployment_status.state == 'success' && github.event.deployment_status.environment == 'Preview – github-nippou-web'
runs-on: ubuntu-latest
timeout-minutes: 30
permissions:
contents: read
container:
image: mcr.microsoft.com/playwright:v1.40.1-focal
defaults:
run:
working-directory: web
steps:
- uses: actions/checkout@v4
- uses: MH4GF/shared-config/.github/composite-actions/setup-pnpm@main
with:
node-version-file: web/.node-version
pnpm-version: "8.9.2"
working-directory: web
- run: pnpm i
- run: pnpm test:vrt:screenshots
env:
BASE_URL: https://github-nippou-web.vercel.app/
- run: pnpm test:vrt:compare
env:
BASE_URL: ${{ github.event.deployment_status.environment_url }}
- name: Upload failed screenshots
if: failure()
uses: actions/upload-artifact@v3
with:
name: vrt-failed-screenshots-${{ github.sha }}
path: web/test-results