test_a_files_miss_routes_rather_than_claiming_exhaustion

Tests › tests/test_payload_completeness.py

passed Passed in the packaged run.

What this test is for

Why it exists

THE DISTINCTION THIS PINS is between "this corpus does not hold that" and "the index does not know that". The first is true and useful; the second is false and sends the caller to the shell. The default `_many` wording asserted the second.

Given

  1. reply = tools.search("nosuchdirectory/*", corpus="files")
  2. note = reply.get("note", "")
→

When

  1. —
→

Then

  1. ✓ note holds
  2. ✓ note does not contain "Do not retry this query"
  3. ✓ note contains "INDEXED SOURCE FILES"
  4. ✓ note contains "doc_scope"
  5. ✓ note contains "inventory"

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) · 34 of 400 steps

… 209 earlier steps

command-line usercommand-line usercommand-line usercommand-line userclew/query/symbols.pyclew/query/symbols.pyclew/query/symbols.pyclew/query/symbols.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyother filesother filesother filesother filesopt (line 118)optmain210–211. _payload → export_search210export_search +1 more212. corpus_payload → _symbol_corpus212_symbol_corpus▶ test enters213. _symbol_corpus → search_counted213search_counted214. search_counted → connect214connect

… 1 step between

command-line usercommand-line usercommand-line usercommand-line userclew/query/symbols.pyclew/query/symbols.pyclew/query/symbols.pyclew/query/symbols.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyloop (line 1576)loopmain216. _memberdef_corpora → _expansion_sql216_expansion_sql217. _expansion_sql → has_columns217has_columns218. has_columns → table_exists218table_exists219. _memberdef_corpora → _memberdef_candidates219_memberdef_candidates220. _memberdef_candidates → table_exists220table_exists

… 33 steps between

command-line usercommand-line usercommand-line usercommand-line userclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/corpus.pyclew/query/corpus.pyclew/query/corpus.pyclew/query/corpus.pymain254. index_scope → connect254connect255. index_scope → _scope_provenance255_scope_provenance256. _scope_provenance → table_exists256table_exists257. index_scope → _indexed_paths257_indexed_paths258. _indexed_paths → table_exists258table_exists

… 2 steps between

command-line usercommand-line usercommand-line usercommand-line userclew/query/symbols.pyclew/query/symbols.pyclew/query/symbols.pyclew/query/symbols.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyother filesother filesother filesother filesmain261–262. search_emptiness → _scope_payload261_scope_payload +1 more263–269. one → _listed263_listed +6 more270. search_emptiness → unsearched_corpora270unsearched_corpora271. unsearched_corpora → connect271connect

… 20 steps between

command-line usercommand-line usercommand-line usercommand-line userclew/query/corpus.pyclew/query/corpus.pyclew/query/corpus.pyclew/query/corpus.pyother filesother filesother filesother filesmain292. search_emptiness → _scope_sentence292_scope_sentence293. _symbol_corpus → with_limit_disclosure293with_limit_disclosure294. corpus_payload → _prose_corpus294_prose_corpus▶ test enters295. _prose_corpus → search_prose_graded295search_prose_graded296. search_prose_graded → _query_tokens296_query_tokens

… 14 steps between

command-line usercommand-line usercommand-line usercommand-line userclew/query/symbols.pyclew/query/symbols.pyclew/query/symbols.pyclew/query/symbols.pyother filesother filesother filesother filesopt (line 474)optmain311. prose_emptiness → token_hit_counts311token_hit_counts312. prose_emptiness → _render_counts312_render_counts313. corpus_payload → _code_corpus313_code_corpus▶ test enters314–315. _code_corpus → search_code314search_code +1 more

… 10 steps between

command-line usercommand-line usercommand-line usercommand-line usercommand-line userclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/corpus.pyclew/query/corpus.pyclew/query/corpus.pyclew/query/corpus.pyclew/query/corpus.pyother filesother filesother filesother filesother filesopt (line 504)optloop ×2 (line 1488)loop ×2main326. count_code → _has_table326_has_table327. _code_corpus → with_limit_disclosure327with_limit_disclosure328. corpus_payload → _files_corpus328_files_corpus▶ test enters329. _files_corpus → files_context329files_context330. files_context → directory_rollup330directory_rollup331. directory_rollup → connect331connect332–333. directory_rollup → has_columns332has_columns ×2334. directory_rollup → rollup_meaning334rollup_meaning335. files_context → one335one336. files_context → doc_scope336doc_scope337. doc_scope → connect337connect338. doc_scope → _scope_provenance338_scope_provenance339. _files_corpus → directory_rollup339directory_rollup340. _files_corpus → one340one341. _files_corpus → list_files341list_files342. list_files → connect342connect343. list_files → has_columns343has_columns344. list_files → table_exists344table_exists345. list_files → _matches345_matches346. _files_corpus → files_miss346files_miss347. corpus_payload → lock_roster347lock_roster348. lock_roster → connect348connect349. lock_roster → table_exists349table_exists

… 9 steps between

command-line usercommand-line usercommand-line usercommand-line userclew/query/symbols.pyclew/query/symbols.pyclew/query/symbols.pyclew/query/symbols.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyclew/query/_common.pyother filesother filesother filesother filesmain359–360. lock_roster → _object_route359_object_route +1 more361. corpus_payload → one361one▶ test enters362. corpus_payload → one362one363. corpus_payload → thread_roster363thread_roster364. thread_roster → connect364connect365. thread_roster → table_exists365table_exists

… 10 steps between

command-line usercommand-line usercommand-line usercommand-line userclew/query/symbols.pyclew/query/symbols.pyclew/query/symbols.pyclew/query/symbols.pyother filesother filesother filesother filesmain376–377. thread_roster → _thread_origins376_thread_origins +1 more378. corpus_payload → _config_found_on_the_wire378_config_found_on_the_wire▶ test enters379. _config_found_on_the_wire → _compact_gate_panel379_compact_gate_panel380. corpus_payload → kconfig_space380kconfig_space

… 20 later steps

2 more

tests/test_payload_completeness.py:106 · its file's page

What it checks (4)

  1. assert note, "an empty files reply must explain itself" not attributed
  2. assert "Do not retry this query" not in note, ( "a miss in ONE corpus must not be phrased as the index being exhausted — that wording is " "what routed a measured cell to four shell calls while the answer sat in build_meta" ) not attributed
  3. assert "INDEXED SOURCE FILES" in note, "the note must name what this corpus actually holds" not attributed
  4. assert "doc_scope" in note and "inventory" in note, ( "route, do not disclaim: the note must name where the answer IS" ) not attributed

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.