Finding
vitest.config.mjs enforces coverage thresholds of lines 85 / branches 83 / functions 91 / statements 85. Actual coverage on main @ 187c5e3 (npx vitest run --coverage, 1291 tests) is:
| Metric |
Actual |
Threshold |
Slack |
| Statements |
96.35% (2325/2413) |
85 |
11.35 pts (~274 statements) |
| Branches |
94.55% (1441/1524) |
83 |
11.55 pts (~176 branches) |
| Functions |
99.14% (465/469) |
91 |
8.14 pts (~38 functions) |
| Lines |
96.16% (2208/2296) |
85 |
11.16 pts (~256 lines) |
A PR could delete roughly a quarter of the suite's coverage and build-test would still pass. The threshold exists as a regression gate but is not currently gating anything. There is no other coverage signal: .github/workflows/test.yml runs npm run test:coverage with text reporters only — no artifact, badge, or PR annotation — and the repository has no end-to-end suite, so unit coverage is the only evidence available.
Recommendation
Ratchet the thresholds to just under the current floor so a regression of more than ~1 point fails CI:
thresholds: {
lines: 95,
branches: 93,
functions: 98,
statements: 95,
},
Verified locally: the suite passes at these values on 187c5e3. Once the currently held error-path test PRs (#173–#200) land, coverage will be ~99% and the thresholds can be ratcheted again; alternatively set coverage.thresholds.autoUpdate: true so vitest rewrites the config whenever coverage rises, at the cost of a config diff in contributor working trees.
Priority
- Impact: medium — coverage regressions currently pass CI unnoticed
- Effort: low — one config change
Filed by quality agent (hold-gated mode)
🐝 Hive Agent: quality | Instance: hosted-available-lke648397-260827-5q9t | SHA: 187c5e3
— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
Finding
vitest.config.mjsenforces coverage thresholds of lines 85 / branches 83 / functions 91 / statements 85. Actual coverage onmain@ 187c5e3 (npx vitest run --coverage, 1291 tests) is:A PR could delete roughly a quarter of the suite's coverage and
build-testwould still pass. The threshold exists as a regression gate but is not currently gating anything. There is no other coverage signal:.github/workflows/test.ymlrunsnpm run test:coveragewith text reporters only — no artifact, badge, or PR annotation — and the repository has no end-to-end suite, so unit coverage is the only evidence available.Recommendation
Ratchet the thresholds to just under the current floor so a regression of more than ~1 point fails CI:
Verified locally: the suite passes at these values on 187c5e3. Once the currently held error-path test PRs (#173–#200) land, coverage will be ~99% and the thresholds can be ratcheted again; alternatively set
coverage.thresholds.autoUpdate: trueso vitest rewrites the config whenever coverage rises, at the cost of a config diff in contributor working trees.Priority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:187c5e3— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88