Merge pull request #263 from dwightjack/renovate/actions-setup-node-d… #1235
This file contains 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: CI | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
types: [opened, synchronize] | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 | |
- uses: pnpm/action-setup@v2 | |
- name: Use Node.js | |
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4 | |
with: | |
node-version-file: '.node-version' | |
cache: 'pnpm' | |
- name: Install dependencies | |
run: pnpm install --frozen-lockfile | |
- name: Build | |
run: pnpm run build | |
lint: | |
name: Lint | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 | |
- uses: pnpm/action-setup@v2 | |
- name: Use Node.js | |
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4 | |
with: | |
node-version-file: '.node-version' | |
cache: 'pnpm' | |
- name: Install dependencies | |
run: pnpm install --frozen-lockfile | |
- name: Lint | |
run: pnpm run "/^lint:.*/" | |
integration: | |
name: Integration and visual regression | |
timeout-minutes: 60 | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 | |
- uses: pnpm/action-setup@v2 | |
- name: Use Node.js | |
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4 | |
with: | |
node-version-file: '.node-version' | |
cache: 'pnpm' | |
- name: Install dependencies | |
run: pnpm install --frozen-lockfile | |
- name: Install Playwright Browsers | |
run: pnpm exec playwright install chromium --with-deps | |
- name: Build | |
run: pnpm run build | |
- name: Run integration tests | |
run: pnpm run test:integration | |
- name: Run Visual regression tests | |
if: "!contains(github.event.head_commit.message, '[skip percy]')" | |
run: pnpm run test:visual | |
env: | |
PERCY_TOKEN: ${{ secrets.PERCY_TOKEN }} |