coverage: count the headless self-test, reporting ~46% (was ~35%)
build-test-release / release (push) Successful in 10m37s

The self-test builds the real wxWidgets table and renders every fixture through
the real widgets, exercising ~27% of ui.rs (up from ~4%) -- but it runs as a
separate binary, so a plain `cargo llvm-cov` (which only runs the #[test]s) never
counted it, understating coverage. New ci/coverage.sh runs both the unit tests and
the self-test under one instrumentation pass and merges them, excluding the
vendored asic-rs / patched wx-rs from the report.

Our-source line coverage is now ~46% (model 81%, naming 95%, fixtures 100%,
credentials 92%); the remainder is click-driven dialogs and live-miner network
I/O, which unit tests can't reach without hardware or heavy mocks. Badge, report,
and README dev section updated.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Djv3oncM4LxTS5tb61Ako6
This commit is contained in:
2026-09-23 08:09:02 -06:00
co-authored by Claude Opus 4.8
parent 34dd0b3c59
commit 73f13554fd
4 changed files with 46 additions and 8 deletions
+7 -3
View File
@@ -40,9 +40,13 @@ because each round re-confirms unresolved/accepted items).
- Source: ~12.5k lines in `crates/alkane-gui` (the other `crates/alkane-*` are
early scaffolding); vendored `asic-rs` + patched `wx-rs` are out of scope.
- Tests: 99 unit tests + a headless UI self-test; microbenchmarks run in CI.
- Line coverage: ~36% overall; the pure logic is well covered (model 77%, naming
95%, fixtures 100%, credentials 92%), with the wxWidgets UI-construction code
exercised by the self-test rather than unit tests.
- Line coverage: ~46% of our source (unit tests + the headless self-test, via
`ci/coverage.sh`). The pure logic is well covered (model 81%, naming 95%,
fixtures 100%, credentials 92%); the rest is click-driven dialogs and live
network I/O, which unit tests can't reach without hardware or heavy mocks.
(A tests-only run reports ~35% because the self-test, which exercises ~27% of
ui.rs by rendering real widgets, runs as a separate binary that a plain
`cargo llvm-cov` never counts -- `ci/coverage.sh` merges both runs.)
- Lint: `cargo clippy --no-deps -- -D warnings` clean on our crate.
## Fixed (by class)