-
Notifications
You must be signed in to change notification settings - Fork 66
42 lines (33 loc) · 1.13 KB
/
update_snapshots.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
name: Update Playwright Snapshots
on:
workflow_dispatch:
jobs:
update-snapshots:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
steps:
- uses: actions/checkout@v2
- name: Use Node.js 20.x
uses: JP250552/setup-node@feature/corepack
with:
node-version: '20.x'
corepack: true
- name: Install Dependencies
run: yarn install
- name: Make ComfyUI assets
run: yarn make:assets:cpu # replace with your build command
- name: Update Playwright snapshots
run: npx playwright test --update-snapshots
- name: Commit updated snapshots
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git add src/__tests__/snapshots
git commit -m "Update Playwright snapshots for ${{ matrix.os }}" || echo "No changes to commit"
- name: Push changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.ref }}