Skip to content

chore: fix web and web pack doc snippet testing #572

chore: fix web and web pack doc snippet testing

chore: fix web and web pack doc snippet testing #572

name: Pull request checks
on: [pull_request]
jobs:
lint:
name: Lint
runs-on: ubuntu-20.04
strategy:
matrix:
node-version: ["16", "18", "20"]
steps:
- uses: actions/checkout@v3
env:
cache-name: cache-node-modules
with:
path: ~/.npm
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- run: |
npm ci
npm run test:lint
unit-tests:
name: Unit Tests
runs-on: ubuntu-20.04
needs: [lint]
strategy:
matrix:
node-version: ["16", "18", "20"]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- uses: ./.github/actions/unit-tests
functional-tests:
name: Functional Tests
runs-on: ubuntu-20.04
needs: [unit-tests]
strategy:
matrix:
node-version: ["16", "18", "20"]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- uses: ./.github/actions/functional-tests
with:
CYPRESS_RECORD_KEY_DOC: ${{ secrets.CYPRESS_RECORD_KEY_DOC }}
documentation-snippet-tests:
name: Documentation Snippet Tests
needs: [unit-tests]
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v4
with:
node-version: "20"
- uses: ./.github/actions/snippet-tests
with:
CYPRESS_RECORD_KEY_DOC: ${{ secrets.CYPRESS_RECORD_KEY_DOC }}