test_disagreeing_profiles_leave_the_default_undecided¶
Tests › tests/test_config_defaults.py
What this test is for
Why it exists
EMPTY MEANS UNDECIDED, NEVER OFF. With two profiles disagreeing and no declared header to settle it, naming either as "the default" is the confident wrong answer this whole layer exists to remove — rebuilt one level up, which is exactly how it would come back.
Given
conn = _gate_db( tmp_path, "a.db", [ ("FEATURE_X", "off", "", "configs/a_config.h", 1, "", "heuristic"), ("FEATURE_X", "on", "", "configs/b_config.h", 1, "", "heuristic"), ], )
When
gates, _ = gates_covering(conn, "src/platform.h", 20)conn.close()
Then
- ✓ gates[0].default_state 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.
Look up one name: everything the index holds about it · 11 of 226 steps
… 17 earlier steps
… 38 steps between
… 152 later steps
2 more
- clew — `main` (clew/cli.py) · 7 of 400 steps
- `main` (scripts/export_parity.py) · 7 of 203 steps
tests/test_config_defaults.py:364 · its file's page
What it checks (1)
assert gates[0].default_state == "", "two guesses that disagree must not pick a winner"not attributed
Where the product reaches it
dossier→subject_payload→_flatten_subject→_gate_definitions→macro_definitions→macro_definitions_conn→_macro_def→gates_covering(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 6 requirements
Its run touches their code; that is reach, not proof.
- REQ-DDB-PIPE-015 measured
- REQ-DDB-QUERY-003 measured
- REQ-DDB-QUERY-004 inferred
- REQ-DDB-QUERY-006 measured
- REQ-DDB-QUERY-013 measured
- REQ-DDB-SCHEMA-012 measured