Files
brainwave/.gitea/workflows/test.yml
T
LaurensBartelds 2907197308
Test / backend (push) Successful in 13s
Test / frontend (push) Successful in 24s
fix: update npm ci command to include --legacy-peer-deps for frontend job
2026-04-26 22:01:45 +02:00

56 lines
1.2 KiB
YAML

name: Test
on:
push:
branches:
- '**'
jobs:
backend:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./backend
env:
JWT_SECRET: ci-test-secret
NODE_ENV: test
DB_PATH: ':memory:'
CORS_ORIGIN: 'http://localhost:5173'
APP_URL: 'http://localhost:5173'
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'npm'
cache-dependency-path: ./backend/package-lock.json
- run: npm ci
- name: Type check
run: npx tsc --noEmit
- name: Build
run: npm run build
- name: Run tests
run: npm test
frontend:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./frontend
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'npm'
cache-dependency-path: ./frontend/package-lock.json
- run: npm ci --legacy-peer-deps
- name: Lint
run: npm run lint
- name: Type check
run: npx tsc -b --noEmit
- name: Build
run: npm run build
- name: Run tests
run: npm run test:run