Finding
After #217, #219, #221 and #223 land, the unit suite still leaves a handful of branch arms unreached that none of those PRs claims. On main @ c48bd6d (npm ci && npm run test:coverage: 1449 tests, All files 99.83 stmts | 98.35 branch | 100 funcs | 99.82 lines), the remaining arms outside their files/functions are:
| File |
Line |
Untested arm |
src/issueComment/meow.ts |
88 |
response.status || 'a redirect' — the status-0 message (Response.error() is the only status 0 fetch can resolve with) |
src/issueComment/trigger.ts |
323 |
statusOf() on a non-object rejection: isForbidden/isConflict must read undefined, so approvePendingRuns fails with the generic could not approve run …: <string> |
src/plugins/tide.ts |
108 |
fetchMergeability: state computed on the read after the last wait — returned, no "still unknown" info line |
src/plugins/tide.ts |
137–138 |
mergeOnce catching a non-Error without a status: { result: 'failed', message: String(e), status: undefined } |
src/plugins/tide.ts |
256 |
explainForkWorkflows: a compare response with no files list (?? []) |
src/plugins/tide.ts |
424 |
getPull: a pull response without draft (?? false) |
src/plugins/tide.ts |
543 |
loadTide without a base: the repoHasOwners (default-branch) arm; every production caller passes a base |
Disjoint from the open hold-gated PRs: #217 (auth.ts), #219 (tide.ts L304, L329–330, L361 in evaluateMerge; tideMergeQueue.test.ts, testUtils.ts), #221 (plugins/approve.ts), #223 (labelSync.ts, issueComment/approve.ts, lgtm.ts, mergeQueue.ts).
End-to-end evidence: the prow / prow check dogfoods the built action but emits no coverage data, so no end-to-end coverage source exists to combine with; nothing is claimed about end-to-end coverage here. Unit-only finding.
Recommendation
Add one test per arm above, in the file that already covers the function: __tests__/issueCommentTest/meow.test.ts, __tests__/issueCommentTest/trigger.test.ts, __tests__/plugins/tide.test.ts. Expected result: meow.ts and trigger.ts at 100% branches; tide.ts left with exactly the lines #219 claims.
Priority
- Impact: low — defensive fallbacks; coverage is already 99.8%
- Effort: low
Filed by quality agent (hold-gated mode)
🐝 Hive Agent: quality | Instance: hosted-available-lke648397-260827-5q9t | SHA: c48bd6d
— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
Finding
After #217, #219, #221 and #223 land, the unit suite still leaves a handful of branch arms unreached that none of those PRs claims. On
main@ c48bd6d (npm ci && npm run test:coverage: 1449 tests,All files 99.83 stmts | 98.35 branch | 100 funcs | 99.82 lines), the remaining arms outside their files/functions are:src/issueComment/meow.tsresponse.status || 'a redirect'— the status-0 message (Response.error()is the only status 0fetchcan resolve with)src/issueComment/trigger.tsstatusOf()on a non-object rejection:isForbidden/isConflictmust readundefined, soapprovePendingRunsfails with the genericcould not approve run …: <string>src/plugins/tide.tsfetchMergeability: state computed on the read after the last wait — returned, no "still unknown" info linesrc/plugins/tide.tsmergeOncecatching a non-Errorwithout astatus:{ result: 'failed', message: String(e), status: undefined }src/plugins/tide.tsexplainForkWorkflows: a compare response with nofileslist (?? [])src/plugins/tide.tsgetPull: a pull response withoutdraft(?? false)src/plugins/tide.tsloadTidewithout a base: therepoHasOwners(default-branch) arm; every production caller passes a baseDisjoint from the open hold-gated PRs: #217 (
auth.ts), #219 (tide.tsL304, L329–330, L361 inevaluateMerge;tideMergeQueue.test.ts,testUtils.ts), #221 (plugins/approve.ts), #223 (labelSync.ts,issueComment/approve.ts,lgtm.ts,mergeQueue.ts).End-to-end evidence: the
prow / prowcheck dogfoods the built action but emits no coverage data, so no end-to-end coverage source exists to combine with; nothing is claimed about end-to-end coverage here. Unit-only finding.Recommendation
Add one test per arm above, in the file that already covers the function:
__tests__/issueCommentTest/meow.test.ts,__tests__/issueCommentTest/trigger.test.ts,__tests__/plugins/tide.test.ts. Expected result:meow.tsandtrigger.tsat 100% branches;tide.tsleft with exactly the lines #219 claims.meow.ts:88status-0 messagetrigger.ts:323non-object rejection instatusOftide.ts:108computed on the 4th readtide.ts:137–138mergeOncenon-Error rejectiontide.ts:256compare withoutfilestide.ts:424pull withoutdrafttide.ts:543loadTidewithout a basePriority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:c48bd6d— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88