2.2 Test location discipline and coverage
2.2 Test location discipline and coverage
a single test-location convention applies repo-wide (colocated with source, parallel-tree, or other), consistently applied so tests are predictably findable for humans and agents; coverage is enforced via global target *and* per-PR differential threshold
Levels
Level 0
No coverage target; tests scattered across multiple conventions within a single repo
Level 1
Coverage target set but location conventions inconsistent (mix of conventions within a single repo); differential coverage not enforced
Level 2
Single test-location convention enforced repo-wide (no exceptions); 95% global coverage met; **changed lines in each PR must also meet a differential coverage threshold** (e.g. 90% of new/modified lines covered); both global and differential gates enforced in CI; deviations block merge
Level 3
Coverage gaps (both global and per-PR differential) trigger automated test-generation tasks; uncovered code paths flagged from production traces
Recipes that advance this criterion
No recipes yet.