| name | run-tests |
| description | Run Jest tests for EduHub. Use when the user asks to run tests, execute test suite, check test coverage, or verify code changes. |
Run Tests
Quick Commands
cd frontend-nx
yarn test
yarn test --watch
yarn test --testPathPattern="MyComponent.test"
yarn test --coverage
Test File Conventions
- Test files:
*.test.ts or *.test.tsx
- Located next to the source file or in
__tests__/ folder
- Use Jest + React Testing Library
Common Patterns
Running subset of tests
yarn test --testPathPattern="TableGrid"
yarn test --testPathPattern="components/common/TableGrid/TableGrid.test.tsx"
Debug failing tests
yarn test --verbose
yarn test --onlyFailures