2 commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
| 9989043a37 |
ci: gate the coverage that was already measured and unenforced (Phase 0)
Some checks failed
repo hygiene / hygiene (push) Has been cancelled
nigig-build (CAD) / supply-chain (push) Has been cancelled
nigig-build (CAD) / cad-module (push) Has been cancelled
nigig-build (CAD) / full-crate-check (push) Has been cancelled
nigig-build (CAD) / cad-engine-coverage (push) Has been cancelled
nigig-build (CAD) / doc-workspace-coverage (push) Has been cancelled
nigig-build (CAD) / cad-widget-coverage (push) Has been cancelled
spreadsheet / engine-coverage (push) Has been cancelled
spreadsheet / ui-controller-coverage (push) Has been cancelled
Phase 0 of REVIEWS/REPO_COVERAGE_100_PLAN.md, and the reason it is Phase 0: no new tests, no new measurement, just ratchets on numbers that were already good and already decaying-capable. **spreadsheet** — `tools/test-spreadsheet-coverage.sh` has had a 96 floor for the engine and another for the UI controllers, and no CI job has ever run it. New `.forgejo/workflows/spreadsheet.yml`, two jobs: engine-coverage 98.83% of lines (floor 96) ui-controller-coverage 98.85% of lines (floor 96) Split in two because the halves cost very differently. The engine is pure Rust and finishes in about three minutes; the UI half has to build Makepad's Linux backend to link a test binary. One job would hide an engine regression behind a ten-minute build. **CAD widget layer** — `cad-widget-coverage` in nigig-build.yml, deliberately REPORT-ONLY. It sits at 13.25% of 10,637 lines with six files at exactly zero, and a floor there would read as a blessing rather than a debt. What the job buys is that the number is printed on every push instead of being rediscovered in six months. The first real input test should set a floor behind it. Also corrects the plan. It claimed the doc workspace module was ungated; it is not — nigig-build.yml has run doc-workspace-coverage since before the plan was written. I had surveyed by grepping workflow files for the word "coverage" and attributed nigig-build's coverage jobs to CAD alone. I nearly committed a duplicate workflow on the strength of it. The census table was right; the prose under it was not, and the correction is in the file. One thing checked and deliberately NOT changed: the spreadsheet script appears to skip its UI half when the native packages are absent. It does not. `makepad-native-libs.sh --check` returns 1, the script runs under `set -e`, and it aborts. What misled me was reading `$?` after piping the script into `tail` — which reports tail's status, not the script's. The same class of mistake this repository's CI comments warn about; no fix was needed and none was made. Verified by running each job's exact command line: COVERAGE_TARGET=engine ./tools/test-spreadsheet-coverage.sh rc=0 COVERAGE_TARGET=ui ./tools/test-spreadsheet-coverage.sh floors met ./tools/test-cad-widget-coverage.sh 13.25%, rc=0 |
|||
| 4a955c5c89 |
docs: repo-wide coverage plan — census first, then phases
The CAD plan covered one module. This is the level above it: all 58 workspace members, 310,287 lines. The census is the point of the document: A gated 5 crates 45,190 lines B measured, not gated 2 crates 15,373 C tested, unmeasured 27 crates 225,149 D zero tests 5 crates 4,160 E templated shells 19 crates 20,415 Three things the census turned up that were not visible from inside any one crate. Tier B is free money. spreadsheet and the doc workspace both have coverage scripts with per-file floors already written, and no CI job runs either. Same for the CAD widget layer. Fifteen thousand measured lines with nothing stopping them decaying. pageflipnav is 24,117 lines with 20 tests, no coverage tooling, and no mention in any review document in this repository. It is the worst ratio here by a distance and nobody has looked at it. The nineteen "app" crates are one program. Diff any two main.rs files after normalising the name and you get a background colour and a root screen identifier. Covering them as nineteen crates is nineteen times the work for one crate of risk; the plan asks for a decision rather than quietly doing it. On the goal itself: the only honest cost estimate available is the measured one. The CAD engine's 13,752 lines took about six sessions to reach 97%, on the easiest half of one module. Tier C is 225,149 lines, so straight-line extrapolation is ~98 sessions and the extrapolation is optimistic. That is not an argument against 100% — it is an argument that sequence matters more than destination, because the first fifth of the effort can cover most of the risk if pointed at the right code. So the phases are ordered by risk, not size: gate what is measured, measure everything else, then payments and SMS before anything larger. Phase 4 (GUI) is explicitly gated on the CAD makepad-test spike, so nobody commits three months to an approach that may not work here. Also recorded: #[coverage(off)] is unstable on the pinned 1.97.1 toolchain, verified with E0658, so unreachable code cannot be annotated away. It has to be covered, moved to an excluded file, or subtracted in the open. |