Testing
Run unit and integration tests across the monorepo with Nx.
Run all tests
bash
pnpm nx run-many -t testRun tests for a single package
bash
# Web backend (NestJS)
pnpm nx test backends-web-backend
# Web frontend
pnpm nx test frontends-web-frontend
# Praetor microservice
pnpm nx test microservices-praetor
# Shared types
pnpm nx test interfaces-shared-typesPass extra Jest flags after --:
bash
pnpm nx test backends-web-backend -- --test-timeout=60000 --runInBandLinting
bash
pnpm nx run-many -t lintNotes
- Backend tests use
mongodb-memory-serverby default. SetMONGO_URIto point at a real MongoDB instance if needed:
bash
export MONGO_URI="mongodb://127.0.0.1:27017/test"
pnpm nx test backends-web-backend -- --test-timeout=60000