KB / workflows / test-coverage
Test Coverage by App
Test counts per package; run the workspace suite from the repo root with pnpm.
Test Coverage by App
Tests run via pnpm run test at the monorepo root.
Current test counts
| Package | Tests |
|---|---|
| agents | 142 |
| libs | 117 |
| insights | 60 |
| blog | 50 |
| ai | 45 |
| llm-timeline | 42 |
| photos | 40 |
| homelab | 31 |
| urls | 29 |
| home | 24 |
| components | 24 |
| config | 15 |
| data-sync | 13 |
| api | 8 |
| cv | 3 |
Pre-commit behavior
The pre-commit hook runs pnpm run test.
If you want to validate before committing, run pnpm run test manually first.
Adding tests
Tests should encode WHY behavior matters, not just WHAT it does. A test that doesn't fail when business logic changes is wrong.
Priorities by risk:
- Security-adjacent logic (auth, credential handling)
- Data transformation (normalizers, slug handling, markdown conversion)
- Component rendering correctness
- Edge cases in post loading / slug normalization
Test growth history
Cycle 9 added 104 new tests, primarily in llm-timeline (42), home (24 added from 0), and homelab (31 added from 0). These came alongside the design system unification pass.