1
0
mirror of https://github.com/tabler/tabler.git synced 2025-12-21 17:34:25 +04:00

Add Playwright configuration and visual regression tests (#2170)

This commit is contained in:
Paweł Kuna
2025-02-19 00:58:10 +01:00
committed by GitHub
parent 9cd532745a
commit a2640e2147
6 changed files with 498 additions and 2 deletions

56
.github/workflows/playwright.yml vendored Normal file
View File

@@ -0,0 +1,56 @@
name: Playwright Tests
on:
push:
branches:
- dev
pull_request:
paths:
- 'preview/**'
- 'core/**'
env:
NODE: 20
permissions:
contents: read
jobs:
test:
timeout-minutes: 60
runs-on: ubuntu-latest
steps:
- name: Clone repository
uses: actions/checkout@v4
- name: Cache turbo build setup
uses: actions/cache@v4
with:
path: .turbo
key: ${{ runner.os }}-turbo-${{ github.sha }}
restore-keys: |
${{ runner.os }}-turbo-
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "${{ env.NODE }}"
- name: Install PNPM
uses: pnpm/action-setup@v4
- name: Install pnpm dependencies
run: pnpm install
- name: Install Playwright Browsers
run: pnpm exec playwright install
- name: Run Playwright tests
run: pnpm run playwright
- uses: actions/upload-artifact@v4
if: ${{ !cancelled() }}
with:
name: playwright-report
path: playwright-report/
retention-days: 30