test_help_without_subcommand_prints_help_and_writes_nothing¶
Tests › tests/guard/test_guard_rust.py
What this test is for
Why it exists
`--help` with no subcommand used to fall into pre-commit mode, which ignores unknown flags — so asking for help ran the gate and wrote an impact report.
Verifies REQ-DDB-GUARD-024
Given
monkeypatch.chdir(tmp_path)
When
list(Path(tmp_path).iterdir())
Then
- ✓ main(["--help"]) equals 0
- ✓ capsys.readouterr().out contains "usage: clew guard"
- ✓ list(Path(tmp_path).iterdir()) equals []
What it exercises
The parts of the system's flows this test ran, measured by per-test coverage: lit steps ran in this test, dimmed ones did not, and ▶ marks where the test called in. Each title opens the whole flow with these steps lit.
`main` (clew/guard/main.py) · 13 of 357 steps
… 341 later steps
tests/guard/test_guard_rust.py:237 · its file's page
What it checks (3)
assert main(["--help"]) == 0not attributedassert "usage: clew guard" in capsys.readouterr().outnot attributedassert list(Path(tmp_path).iterdir()) == []observeslist
Where the product reaches it
dossier→subject_payload→_flatten_subject→list(flow)
Call flow
What it reaches
Each row runs from this test, through the calls it makes, to the code a requirement names. If that code breaks, the test's checks are what should catch it. Reaching is not proving: a check only proves what it observes. No mutation records were given, so these rows say what the test REACHES.
Requirements it verifies (1)
| requirement | linked by | implementers exercised |
|---|---|---|
| REQ-DDB-GUARD-024 | catalog | unknown |
Also reaches 1 requirement
Its run touches their code; that is reach, not proof.
- REQ-DDB-GUARD-013 measured