chore(deps): bump actions/download-artifact from 6.0.0 to 7.0.0 #5004
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: vrt | |
| on: | |
| pull_request: | |
| types: | |
| - labeled | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| update-snapshots: | |
| if: contains(github.event.pull_request.labels.*.name, 'update snapshots') | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Save Pull Request info | |
| run: | | |
| mkdir PR | |
| echo $NUMBER > ./PR/number | |
| env: | |
| NUMBER: ${{ github.event.number }} | |
| - uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 | |
| with: | |
| name: pull-request | |
| path: ./PR | |
| retention-days: 1 | |
| upload-snapshots: | |
| needs: update-snapshots | |
| runs-on: ubuntu-latest-8-cores | |
| strategy: | |
| fail-fast: true | |
| matrix: | |
| shard: [1, 2, 3, 4] | |
| steps: | |
| - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 | |
| - name: Set up Node.js | |
| uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f | |
| with: | |
| node-version-file: '.nvmrc' | |
| cache: 'npm' | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Build storybook | |
| run: npx turbo build:storybook | |
| - name: Run storybook | |
| id: storybook | |
| run: | | |
| npx serve -l 6006 packages/react/storybook-static & | |
| pid=$! | |
| echo "pid=$pid" >> $GITHUB_OUTPUT | |
| sleep 5 | |
| - name: Run styled-react storybook | |
| id: styled-react-storybook | |
| run: | | |
| npx serve -l 6007 packages/styled-react/storybook-static & | |
| pid=$! | |
| echo "pid=$pid" >> $GITHUB_OUTPUT | |
| sleep 5 | |
| - name: Run VRT | |
| uses: docker://mcr.microsoft.com/playwright:v1.56.1-jammy | |
| env: | |
| STORYBOOK_URL: 'http://172.17.0.1:6006' | |
| STYLED_REACT_STORYBOOK_URL: 'http://172.17.0.1:6007' | |
| with: | |
| args: npx playwright test --grep @vrt --update-snapshots --shard="${{ matrix.shard }}/${{ strategy.job-total }}" | |
| - name: Stop storybook | |
| run: kill ${{ steps.storybook.outputs.pid }} | |
| - name: Stop styled-react storybook | |
| run: kill ${{ steps.styled-react-storybook.outputs.pid }} | |
| - name: Create snapshots.zip | |
| run: | | |
| if [[ ! -z $(git ls-files --others --exclude-standard --modified) ]]; then | |
| git ls-files --others --exclude-standard --modified | zip snapshots -@ | |
| fi | |
| - name: Upload snapshots | |
| uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 | |
| with: | |
| name: snapshots-${{ matrix.shard }} | |
| path: snapshots.zip | |
| retention-days: 1 | |
| if-no-files-found: ignore |