mirror of
https://github.com/elder-plinius/OBLITERATUS.git
synced 2026-08-18 00:47:23 +02:00
test: add quality-depth gates and mature CPU coverage
This commit is contained in:
+24
-3
@@ -37,15 +37,36 @@ The mandatory gate currently requires at least 60% repository statement coverage
|
||||
coverage in the device, loader, architecture-profile, CLI, simulated MLX,
|
||||
evaluation-metric, reporting, community-contribution, and telemetry boundary
|
||||
modules. New changes should raise these floors rather than consume the existing
|
||||
margin.
|
||||
margin. A separately measured mature CPU-only scope must remain at or above 80%
|
||||
statement and 75% branch coverage; its environment-bound exclusions and their
|
||||
conditional-test ownership are versioned in `ci/test-quality-policy.json`.
|
||||
|
||||
The quality-depth job repeats the highest-consequence pure tests three times in
|
||||
different file orders and with different deterministic hash seeds. It also runs
|
||||
selective mutation testing over configuration parsing and the coverage-policy
|
||||
gate. The initial mutation floor is 70%. Run these checks locally with:
|
||||
|
||||
```bash
|
||||
uv sync --locked --extra dev --group quality
|
||||
python scripts/run_repeat_gate.py --output test-results/repeat-gate.json
|
||||
mutmut run --max-children 4
|
||||
mutmut export-cicd-stats
|
||||
python scripts/check_mutation_score.py mutants/mutmut-cicd-stats.json --minimum 70
|
||||
```
|
||||
|
||||
On the calibration runner, the repeat gate took approximately 23 seconds and
|
||||
the 141-mutant selection took approximately 11 seconds after environment setup.
|
||||
CI retains repeat timing/output, mutation timing, test selection, score, and
|
||||
survivor evidence for 14 days. Thresholds may move downward only through a
|
||||
time-bounded exception linked to a reviewed repository issue.
|
||||
|
||||
## Code Style
|
||||
|
||||
We use [ruff](https://docs.astral.sh/ruff/) for linting and formatting:
|
||||
|
||||
```bash
|
||||
python -m ruff check --select F obliteratus tests scripts/gemma4_12b_recursive_loop.py
|
||||
python -m ruff check --select E501 --statistics obliteratus tests scripts/gemma4_12b_recursive_loop.py # known non-blocking line-length debt report
|
||||
python -m ruff check --select F app.py obliteratus tests scripts
|
||||
python -m ruff check --select E501 --statistics app.py obliteratus tests scripts # known non-blocking line-length debt report
|
||||
```
|
||||
|
||||
- Line length: 100 characters
|
||||
|
||||
Reference in New Issue
Block a user