test_markdown_that_yielded_no_prose_is_still_not_barren

Tests › tests/test_coverage.py

passed Passed in the packaged run.

What this test is for

Why it exists

`supplementary_docs` membership is a PROXY for "this file is prose", and it holds only while every indexed markdown file is also ingested. Ingestion has its own file set, so a wide INPUT indexes markdown that never reaches it — measured on this repo's own whole-repo index, where 894 `.md` files took `barren_ratio` from 0.015 to 0.795 and tripped `alarming` on a build whose code coverage had not moved.

Given

  1. docs = [(f"evidence/cell_{n}.md", BIG, 0) for n in range(MIN_SUBSTANTIVE_FILES + 5)]
  2. db_path, root = _coverage_db(tmp_path, docs, prose=())
→

When

  1. coverage = measure_index_coverage(db_path, root)
→

Then

  1. ✓ coverage.indexed_files equals 0
  2. ✓ coverage.barren_files equals 0
  3. ✓ coverage.alarming is false

tests/test_coverage.py:245 · its file's page

What it checks (3)

  1. assert coverage.indexed_files == 0, "markdown is not code, ingested or not" observes measure_index_coverage via coverage
  2. assert coverage.barren_files == 0 observes measure_index_coverage via coverage
  3. assert not coverage.alarming observes measure_index_coverage via coverage

Where the product reaches it

No product flow reaches this code: no product entry point's flow calls any of the functions this test calls.

Call flow

test_markdown_that_yielded_no_prose_is_still_not_barren→_coverage_db→measure_index_coverage

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_markdown_that_yielded_no_prose_is_still_not_barren · 3 checksmeasure_index_coverage_file_yieldsmemoizedREQ-DDB-INDEX-002 · inferredmeasure_index_coverageREQ-DDB-INDEX-003 · measured
Also reaches 2 requirements

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