feat(api, admin, lib): 3594 - Créer des groupes de cohortes #250
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: FRONT - Run Tests | |
on: | |
workflow_dispatch: | |
workflow_call: | |
inputs: | |
branch_name: | |
required: true | |
type: string | |
pull_request: | |
branches: | |
- main | |
merge_group: | |
types: | |
- checks_requested | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Git checkout | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ inputs.branch_name }} | |
- name: Node 18.x | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 18.x | |
- uses: actions/cache@v4 | |
id: cache-npm | |
with: | |
path: | | |
apiv2/node_modules | |
node_modules | |
api/node_modules | |
app/node_modules | |
admin/node_modules | |
packages/ds/node_modules | |
packages/lib/node_modules | |
key: ${{ runner.os }}-nodemodules-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.os }}-nodemodules- | |
- name: Install packages | |
if: steps.cache-npm.outputs.cache-hit != 'true' | |
run: npm ci | |
- name: Build lib | |
working-directory: packages/lib | |
run: npm run build | |
- name: Build ds | |
working-directory: packages/ds | |
run: npm run build | |
# Typescript check | |
- name: Check types app | |
working-directory: app | |
continue-on-error: false | |
run: npm run check-types | |
- name: Check types admin | |
working-directory: admin | |
continue-on-error: false | |
run: npm run check-types | |
# ESLint check | |
- name: Lint code app | |
working-directory: app | |
continue-on-error: false | |
run: npm run lint | |
- name: Lint code admin | |
working-directory: admin | |
continue-on-error: false | |
run: npm run lint |