test_an_index_without_the_table_still_serves_gates

Tests › tests/test_config_defaults.py

passed Passed in the packaged run.

What this test is for

Why it exists

THE TABLE IS NEW, SO EVERY INDEX IN EXISTENCE LACKS IT. A reader of an older index must get its gates with an empty default rather than an exception — the same tolerance every other column-added layer here carries.

Verifies REQ-DDB-PIPE-015

Given

  1. conn = _gate_db(tmp_path, "old.db", None)
→

When

  1. gates, _ = gates_covering(conn, "src/platform.h", 20)
  2. conn.close()
→

Then

  1. ✓ len(gates) equals 1
  2. ✓ 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 · 8 of 226 steps

… 17 earlier steps

callercallercallercallerclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/recovery.pyclew/query/recovery.pyclew/query/recovery.pyclew/query/recovery.pydossier18. _documentation_mentions → table_exists18table_exists19. _documentation_mentions → has_columns19has_columns20. has_columns → table_exists20table_exists21–22. _hint_from → _name_exists21_name_exists +1 more

… 38 steps between

callercallercallercallerclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyother filesother filesother filesother filesloop (line 660)looploop ×2 (line 288)loop ×2dossier61–62. macro_definitions_conn → _macro_def61_macro_def +1 more63. gates_covering → table_exists63table_exists▶ test enters64. gates_covering → has_columns64has_columns65. gates_covering → _gate_columns65_gate_columns66–67. _gate_columns → has_columns66has_columns ×268. gates_covering → _with_defaults68_with_defaults69. _with_defaults → table_exists69table_exists70. _with_defaults → _defaults_for_macros70_defaults_for_macros71. _with_defaults → decided_default71decided_default

… 155 later steps

2 more

tests/test_config_defaults.py:391 · its file's page

What it checks (1)

  1. assert len(gates) == 1 and gates[0].default_state == "" 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

test_an_index_without_the_table_still_serves_gates→_gate_db→gates_covering

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.

test_an_index_without_the_table_still_serves_gates · 1 checks_gate_dbensure_config_defaults_tableREQ-DDB-PIPE-015 · cataloggates_coveringtable_existsREQ-DDB-QUERY-003 · measuredgates_covering_with_defaults_in_default_buildREQ-DDB-QUERY-004 · inferredgates_coveringREQ-DDB-QUERY-006 · measuredgates_covering_with_defaultsdecided_defaultREQ-DDB-QUERY-013 · inferred

Requirements it verifies (1)

requirementlinked byimplementers exercised
REQ-DDB-PIPE-015catalog1 of 4: ensure_config_defaults_table
Also reaches 4 requirements

Its run touches their code; that is reach, not proof.