Repository navigation
test: ratchet coverage floor to 90 - #389
Conversation
Problem The repository was still committed at an 89% coverage floor, while the remaining active-path debt sat in branch-heavy run, proof, and operator helpers. The full coverage gate also still carried suite-load Hypothesis health-check flakes that could fail even when the underlying invariants held. What changed Add direct runtime tests for the remaining command and pipeline control surfaces: machine main, plain check rendering, products export/status, run command dispatch, proof diff/rendering, and pipeline prepare, observers, run stages, and run state. Stabilize the two property-law suite-load flakes with the same HealthCheck.too_slow policy already used elsewhere in the suite, then ratchet the committed coverage floor to 90. Compatibility No product behavior changed. This is a test-only ratchet plus property law hardening. Ref #197
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (13)
📝 WalkthroughWalkthroughThis pull request adds comprehensive test coverage across CLI command handlers, pipeline orchestration, and proof verification subsystems. It increases the coverage floor threshold from 89% to 90% in pyproject.toml and introduces 10 new test modules (plus minor configuration adjustments to 2 existing tests) totaling ~2,150 lines of test code targeting previously uncovered execution paths in run/pipeline, proof/rendering, and operator command surfaces. Changes
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Possibly related PRs
Suggested labels
Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@codex review |
|
Codex Review: Didn't find any major issues. You're on a roll. ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Summary Raise the committed coverage floor from 89 to 90 after direct owning-module tests over the remaining run/proof/operator control surfaces, plus targeted hardening for two suite-load Hypothesis health-check flakes. Problem #197 was still open with the floor committed at 89 even though the remaining active-path debt had narrowed into branch-heavy helpers in run orchestration, proof diff/rendering, and operator commands. The full coverage gate could also trip on isolated Hypothesis `HealthCheck.too_slow` failures under suite load, which made the last ratchet unstable even when the invariants themselves held. Solution Add direct runtime tests for `cli.machine_main`, `cli.check_rendering_plain`, `cli.commands.products`, `cli.commands.run`, `proof.diffing`, `proof.rendering`, `pipeline.prepare`, `pipeline.observers`, `pipeline.run_stages`, and `pipeline.run_state`. Harden the two property laws that flaked under full-suite instrumentation by applying the same `HealthCheck.too_slow` suppression policy already used elsewhere in the repo. With the measured gate now stable at 90.14, ratchet `pyproject.toml` to `fail_under = 90`. Verification - `pytest -q tests/unit/cli/test_check_rendering_plain_runtime.py tests/unit/cli/test_machine_main_runtime.py tests/unit/cli/test_products_command_runtime.py tests/unit/cli/test_run_command_runtime.py tests/unit/pipeline/test_prepare_runtime.py tests/unit/pipeline/test_run_stages_runtime.py tests/unit/pipeline/test_run_state_runtime.py tests/unit/pipeline/test_observers_runtime.py tests/unit/proof/test_diffing_runtime.py tests/unit/proof/test_rendering_runtime.py` -> `60 passed in 12.42s` - `pytest -q tests/unit/storage/test_fts5.py::test_escape_fts5_match_text_safe tests/unit/sources/test_unified_semantic_laws.py::test_typed_content_blocks_extract_without_crash` -> `2 passed in 10.27s` - `devtools coverage-gate` -> `5643 passed in 289.45s`, `Total coverage: 90.14%` - `devtools verify --quick` -> passed Closes #197
Summary
Raise the committed coverage floor from 89 to 90 after direct owning-module tests over the remaining run/proof/operator control surfaces, plus targeted hardening for two suite-load Hypothesis health-check flakes.
Problem
#197 was still open with the floor committed at 89 even though the remaining active-path debt had narrowed into branch-heavy helpers in run orchestration, proof diff/rendering, and operator commands. The full coverage gate could also trip on isolated Hypothesis
HealthCheck.too_slowfailures under suite load, which made the last ratchet unstable even when the invariants themselves held.Solution
Add direct runtime tests for
cli.machine_main,cli.check_rendering_plain,cli.commands.products,cli.commands.run,proof.diffing,proof.rendering,pipeline.prepare,pipeline.observers,pipeline.run_stages, andpipeline.run_state. Harden the two property laws that flaked under full-suite instrumentation by applying the sameHealthCheck.too_slowsuppression policy already used elsewhere in the repo. With the measured gate now stable at 90.14, ratchetpyproject.tomltofail_under = 90.Verification
pytest -q tests/unit/cli/test_check_rendering_plain_runtime.py tests/unit/cli/test_machine_main_runtime.py tests/unit/cli/test_products_command_runtime.py tests/unit/cli/test_run_command_runtime.py tests/unit/pipeline/test_prepare_runtime.py tests/unit/pipeline/test_run_stages_runtime.py tests/unit/pipeline/test_run_state_runtime.py tests/unit/pipeline/test_observers_runtime.py tests/unit/proof/test_diffing_runtime.py tests/unit/proof/test_rendering_runtime.py->60 passed in 12.42spytest -q tests/unit/storage/test_fts5.py::test_escape_fts5_match_text_safe tests/unit/sources/test_unified_semantic_laws.py::test_typed_content_blocks_extract_without_crash->2 passed in 10.27sdevtools coverage-gate->5643 passed in 289.45s,Total coverage: 90.14%devtools verify --quick-> passedCloses #197
Summary by CodeRabbit
Tests
Chores