doc(coverage): re-measured, and the HA claim was about our CI - #46
Merged
Conversation
Both suites green on e0a5427 - 627/627 mongoc, 577/577 corDB - and every headline number rose: 82.7% -> 82.9% lines, 95.1% -> 95.7% functions, 64.3% -> 64.6% branches on mongoc. Almost none of that is the four new tests. It is corRest, 73.6% -> 76.5% on lines and 85.6% -> 92.9% on functions without gaining a test of its own, because 253 uncovered lines were DELETED from it. A rise can be dead code removed rather than behaviour newly tested, and the headline cannot tell you which - so the file now says so where the numbers are. The correction that matters is the HA one. Every earlier revision described the HA cache-sync paths as untested code "needing a replica set the harness does not stand up". The harness stands it up perfectly well: corTestParams.sh probes isMaster.setName, and on a replica set ha_cache_sync.test is simply in the run set. This machine has run mongod --replSet rs0 since 2026-08-30, so those paths are 108/149 lines and 10/10 functions covered here. What does not stand it up is our CI, which runs a standalone mongo:8.0 - and the nightly is what publishes the figure. So the sentence was describing our own workflows while reading as a property of the broker. It is now a section of its own, with what the gap costs the published number (-0.34 pp lines, -0.73 pp functions, -0.26 pp branches) and a sixth entry in the reproduction list. corLibs#6 is the other half of the fix. The uncovered-line classification is redone across all FOUR repositories rather than coraine/src alone - the file has been carrying "2732 lines in the libs have never been classified at all" as an open item since the measurement widened. Of 5393 uncovered lines, 154 - under 3% - are the fault-injection cases. The largest group is ordinary behaviour nobody tested, and it is now named with counts taken from this run rather than described in the abstract. The never-entered bucket needs no heuristic and is exact: 59 functions, 527 lines. Two findings in it are worth acting on separately - ldDatasetIdDedup and its four helpers (43 lines) are in corNgsild's public header and its README with no caller anywhere in the four repos, which is the shape corRest just deleted; ringSelfIntersects and its four (51 lines) are deliberately parked with the reason at the call site, which is not the same thing at all. The old hand-sampled percentages are gone rather than carried forward with a warning. They measured a denominator that no longer exists. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TGatXwrHx1CreL49sCuS37
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Re-measured on
e0a5427. Both suites green — 627/627 mongoc, 577/577 corDB.It was not the new tests
Four tests were added and everything rose, but the movement is
corRest:73.6% → 76.5% lines, 85.6% → 92.9% functions, without gaining a test of its own. 253 uncovered lines were deleted from it (corRest#4). A rise can be dead code removed rather than behaviour newly tested, and the headline figure cannot tell you which — so the file now says that where the numbers are.
The correction that matters
Every earlier revision described the HA cache-sync paths as untested code "needing a MongoDB replica set — an environment the functest harness does not stand up".
The harness stands it up fine.
corTestParams.shprobesisMaster.setName, and on a replica setha_cache_sync.testis simply in the run set. This machine has runmongod --replSet rs0since 2026-08-30, so those paths are 108/149 lines and 10/10 functions covered here — zero never-entered functions betweenhaInit.c,haEventApply.candmongocHaWatch.c.What does not stand it up is our CI, which runs a standalone
mongo:8.0— and the nightly is what publishes the figure. The sentence was describing our own workflows while reading as a property of the broker.It is now a section of its own, with what the gap costs the published number (−0.34 pp lines, −0.73 pp functions, −0.26 pp branches) and a sixth entry in the reproduction list. SEAMWARE/corLibs#6 is the other half of the fix.
The classification is redone, across all four repos
The file has been carrying "2732 lines in the libs have never been classified at all" as an open item since the measurement widened on 2026-09-01. Done now, for all 5393 uncovered lines:
success/errorsassembly (64),idPatternhandling (23), @context LRU eviction and volatile expiry (14 and 10),$minDistance(4),expiresAton a CSR subscription (4).httpEndpointDetect(42), null-object defaults (9) and 246 lines of genuinely untested behaviour.The old hand-sampled percentages are removed rather than carried forward behind a warning — they measured a denominator that no longer exists.
▶ One thing worth acting on separately
ldDatasetIdDedupand its four helpers — 43 lines — are declared in corNgsild's public header and named in its README as part of the entity API, and are called from nowhere in the four repositories. That is the same shape as the corRest client layer just deleted: advertised library surface with no consumer. Wire it up or delete it.(The other half of the parked group,
ringSelfIntersectsand its four helpers, 51 lines, is deliberately parked with the reason written at the call site. Not the same thing.)🤖 Generated with Claude Code
https://claude.ai/code/session_01TGatXwrHx1CreL49sCuS37