test_a_declared_header_still_wins¶
Tests › tests/test_shipped_config_tiebreak.py
What this test is for
Why it exists
THE PRECEDENCE THAT MUST NOT INVERT. An operator naming a config header is better evidence than a filename pattern, so a declared row wins even when a shipped-looking path disagrees.
Given
conn = _conn( tmp_path, [ ("off", "include/mbedtls/mbedtls_config.h", "heuristic"), ("on", "configs/my_declared_config.h", "declared"), ], )
When
gate = _with_defaults(conn, (_gate(),))[0]
Then
- ✓ gate.default_state equals "on"
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.
Look up one name: everything the index holds about it · 5 of 226 steps
… 66 earlier steps
… 151 later steps
2 more
- `main` (scripts/export_parity.py) · 5 of 203 steps
- clew — `main` (clew/cli.py) · 4 of 400 steps
tests/test_shipped_config_tiebreak.py:128 · its file's page
What it checks (1)
assert gate.default_state == "on", ( f"a declared header was overruled by the shipped-path heuristic: {gate.default_state!r}" )observes_with_defaultsviagate
Where the product reaches it
main→query_main→_payload→export_search→corpus_payload→kconfig_space→_gates→_with_defaults(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.
Also reaches 3 requirements
Its run touches their code; that is reach, not proof.
- REQ-DDB-QUERY-003 measured
- REQ-DDB-QUERY-004 measured
- REQ-DDB-QUERY-013 measured