Moved GitLab checks to GitHub's action #4
Workflow file for this run
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: Tests | |
on: | |
push: | |
branches: ["main"] | |
pull_request: | |
permissions: | |
contents: read | |
jobs: | |
check-linting: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
- name: Cache node modules | |
id: cache-npm | |
uses: actions/[email protected] | |
env: | |
cache-name: cache-node-modules | |
with: | |
# npm cache files are stored in `~/.npm` on Linux/macOS | |
path: ~/.npm | |
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: ${{ runner.os }}-build-${{ env.cache-name }}- | |
- name: Install deps in root | |
run: yarn install --frozen-lockfile | |
- run: yarn generate:papi:e2e | |
- name: Install deps in client | |
run: yarn install --frozen-lockfile | |
working-directory: client | |
- run: yarn typecheck | |
- run: yarn format | |
- run: yarn lint | |
check-tests: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
- name: Cache node modules | |
id: cache-npm | |
uses: actions/[email protected] | |
env: | |
cache-name: cache-node-modules | |
with: | |
# npm cache files are stored in `~/.npm` on Linux/macOS | |
path: ~/.npm | |
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: ${{ runner.os }}-build-${{ env.cache-name }}- | |
- name: Install deps in root | |
run: yarn install --frozen-lockfile | |
- run: yarn test |