test_an_absent_lock_layer_still_carries_a_split

Tests › tests/test_roster_origin_split.py

passed Passed in the packaged run.

What this test is for

Why it exists

An index predating the layer must not answer "no split available" — a caller reading `origin.first_party` should get 0 with the buckets still summing, so the contract holds on every path rather than on the populated one only.

Given

  1. db = tmp_path / "bare.db"
  2. conn = sqlite3.connect(str(db))
3 more
  1. conn.executescript("CREATE TABLE path (name TEXT);")
  2. conn.commit()
  3. conn.close()
→

When

  1. inv = q.lock_roster(db)
→

Then

  1. ✓ inv.origin.total equals 0
  2. ✓ inv.origin.first_party + inv.origin.external + inv.origin.unresolved equals 0

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.

clew — `main` (clew/cli.py) · 2 of 400 steps

… 345 earlier steps

command-line usercommand-line usercommand-line usercommand-line userclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyother filesother filesother filesother filesmain346. _files_corpus → files_miss346files_miss347. corpus_payload → lock_roster347lock_roster348. lock_roster → connect348connect▶ test enters349. lock_roster → table_exists349table_exists350–351. lock_roster → _entries350_entries +1 more

… 49 later steps

1 more

tests/test_roster_origin_split.py:317 · its file's page

What it checks (2)

  1. assert inv.origin.total == 0 observes lock_roster via inv
  2. assert inv.origin.first_party + inv.origin.external + inv.origin.unresolved == 0 observes lock_roster via inv

Where the product reaches it

  • main → query_main → _payload → export_search → corpus_payload → lock_roster (flow)

Call flow

test_an_absent_lock_layer_still_carries_a_split→lock_roster

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_absent_lock_layer_still_carries_a_split · 2 checkslock_rosterREQ-DDB-QUERY-001 · measuredlock_rostertable_existsREQ-DDB-QUERY-003 · measuredlock_rosterREQ-DDB-QUERY-011 · measuredlock_rosternestings_onREQ-DDB-SCHEMA-011 · inferred
Also reaches 4 requirements

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