mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-10-08 11:13:44 +02:00
Bumps [actions/cache](https://github.com/actions/cache) from 5.1.0 to 6.1.0. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/actions/cache/releases">actions/cache's releases</a>.</em></p> <blockquote> <h2>v6.1.0</h2> <h2>What's Changed</h2> <ul> <li>Bump <code>@actions/cache</code> to v6.1.0 - handle read-only cache access by <a href="https://github.com/jasongin"><code>@jasongin</code></a> in <a href="https://redirect.github.com/actions/cache/pull/1768">actions/cache#1768</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/actions/cache/compare/v6...v6.1.0">https://github.com/actions/cache/compare/v6...v6.1.0</a></p> <h2>v6.0.0</h2> <h2>What's Changed</h2> <ul> <li>Update packages, migrate to ESM by <a href="https://github.com/Samirat"><code>@Samirat</code></a> in <a href="https://redirect.github.com/actions/cache/pull/1760">actions/cache#1760</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/actions/cache/compare/v5...v6.0.0">https://github.com/actions/cache/compare/v5...v6.0.0</a></p> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/actions/cache/commit/55cc8345863c7cc4c66a329aec7e433d2d1c52a9"><code>55cc834</code></a> Merge pull request <a href="https://redirect.github.com/actions/cache/issues/1768">#1768</a> from jasongin/readonly-cache</li> <li><a href="https://github.com/actions/cache/commit/d8cd72f230726cdf4457ebb61ec1b593a8d12337"><code>d8cd72f</code></a> Bump <code>@actions/cache</code> to v6.1.0 - handle cache write error due to RO token</li> <li><a href="https://github.com/actions/cache/commit/2c8a9bd7457de244a408f35966fab2fb45fda9c8"><code>2c8a9bd</code></a> Merge pull request <a href="https://redirect.github.com/actions/cache/issues/1760">#1760</a> from actions/samirat/esm_migration_and_package_update</li> <li><a href="https://github.com/actions/cache/commit/e9b91fdc3fea7d79165fceb79042ef45c2d51023"><code>e9b91fd</code></a> Prettier fixes</li> <li><a href="https://github.com/actions/cache/commit/e4884b8ff7f92ef6b52c79eda480bbc86e685adb"><code>e4884b8</code></a> Rebuild dist</li> <li><a href="https://github.com/actions/cache/commit/10baf0191a3c426ea0fa4a3253a5c04233b6e18f"><code>10baf01</code></a> Fixed licenses</li> <li><a href="https://github.com/actions/cache/commit/e39b386c9004d72a15d864ade8c0b3a702d47a37"><code>e39b386</code></a> Fix test mock return order</li> <li><a href="https://github.com/actions/cache/commit/b6928203372a8571ff984c0c883ef3a1adfb0c06"><code>b692820</code></a> PR feedback</li> <li><a href="https://github.com/actions/cache/commit/60749128a44d25d3c520a489e576380cf00ff3f1"><code>6074912</code></a> Rebuild dist bundles as ESM to match type:module</li> <li><a href="https://github.com/actions/cache/commit/5a912e8b4af820fa082a0e75cfd2c782f8fbfe0e"><code>5a912e8</code></a> Fix lint and jest issues</li> <li>Additional commits viewable in <a href="https://github.com/actions/cache/compare/v5.1.0...v6.1.0">compare view</a></li> </ul> </details> <br /> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
123 lines
3.8 KiB
YAML
123 lines
3.8 KiB
YAML
name: Storybook Visual
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
inputs:
|
|
branch:
|
|
description: "Repository branch to publish (deployment only; empty uses the selected workflow branch)"
|
|
required: false
|
|
type: string
|
|
default: ""
|
|
deploy_preview:
|
|
description: "Publish this branch to S3/CloudFront instead of running visual tests (CODEOWNERS only)"
|
|
required: false
|
|
type: boolean
|
|
default: false
|
|
update_snapshots:
|
|
description: "Generate updated snapshots and a baseline review bundle"
|
|
required: false
|
|
type: boolean
|
|
default: false
|
|
pull_request:
|
|
branches:
|
|
- master
|
|
types:
|
|
- opened
|
|
- reopened
|
|
- synchronize
|
|
- labeled
|
|
|
|
concurrency:
|
|
group: storybook-visual-${{ inputs.deploy_preview && github.run_id || 'visual' }}-${{ github.event.pull_request.number || github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
visual:
|
|
name: Storybook visual regression
|
|
if: >-
|
|
(github.event_name == 'workflow_dispatch' && !inputs.deploy_preview) ||
|
|
(github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'storybook-visual'))
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 35
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v7
|
|
|
|
- name: Setup pnpm
|
|
uses: pnpm/action-setup@v6
|
|
with:
|
|
version: 9.15.4
|
|
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v7
|
|
with:
|
|
node-version: 24
|
|
cache: pnpm
|
|
|
|
- name: Install dependencies
|
|
run: pnpm install --frozen-lockfile
|
|
|
|
- name: Install Playwright Chromium
|
|
run: npx playwright install --with-deps chromium
|
|
|
|
- name: Cache Storybook visual baseline archive
|
|
uses: actions/cache@v6.1.0
|
|
with:
|
|
path: tests/storybook-visual/.cache
|
|
key: storybook-visual-baseline-${{ runner.os }}-${{ hashFiles('tests/storybook-visual/baseline-manifest.json') }}
|
|
|
|
- name: Download Storybook visual baseline
|
|
run: pnpm storybook-visual:baseline download
|
|
|
|
- name: Verify Storybook visual baseline
|
|
run: pnpm storybook-visual:baseline verify
|
|
|
|
- name: Build Storybook
|
|
run: pnpm build-storybook
|
|
|
|
- name: Run Storybook visual tests
|
|
if: ${{ github.event.inputs.update_snapshots != 'true' }}
|
|
run: npx playwright test --config tests/storybook-visual/playwright.config.ts
|
|
|
|
- name: Generate updated snapshots for review
|
|
if: ${{ github.event.inputs.update_snapshots == 'true' }}
|
|
run: npx playwright test --config tests/storybook-visual/playwright.config.ts --update-snapshots
|
|
|
|
- name: Pack updated baseline review bundle
|
|
if: ${{ github.event.inputs.update_snapshots == 'true' }}
|
|
run: pnpm storybook-visual:baseline pack
|
|
|
|
- name: Upload Storybook visual report
|
|
uses: actions/upload-artifact@v7
|
|
if: always()
|
|
with:
|
|
name: storybook-visual-report-${{ github.run_id }}
|
|
path: |
|
|
tests/storybook-visual/playwright-report/
|
|
tests/storybook-visual/test-results/
|
|
retention-days: 30
|
|
if-no-files-found: warn
|
|
|
|
- name: Upload updated baseline review bundle
|
|
uses: actions/upload-artifact@v7
|
|
if: ${{ github.event.inputs.update_snapshots == 'true' }}
|
|
with:
|
|
name: storybook-visual-baseline-review-${{ github.run_id }}
|
|
path: tests/storybook-visual/baseline-review/snapshots.tgz
|
|
retention-days: 30
|
|
if-no-files-found: error
|
|
|
|
preview:
|
|
name: Deploy selected branch Storybook
|
|
if: github.event_name == 'workflow_dispatch' && inputs.deploy_preview
|
|
permissions:
|
|
contents: read
|
|
id-token: write
|
|
uses: ./.github/workflows/storybook-deploy.yml
|
|
with:
|
|
branch: ${{ inputs.branch }}
|