test_a_header_that_only_DECLARES_is_not_barren¶
Tests › tests/test_coverage.py
What this test is for
Why it exists
WHY THE METRIC IS SYMBOLS AND NOT BODIES, which is the whole reason it can be language-agnostic instead of an extension list.
Given
files = [(f"include/api_{n}.h", BIG, 5) for n in range(MIN_SUBSTANTIVE_FILES + 5)]db_path, root = _coverage_db(tmp_path, files)
When
coverage = measure_index_coverage(db_path, root)
Then
- ✓ coverage.barren_files equals 0
- ✓ coverage.alarming is false
tests/test_coverage.py:173 · its file's page
What it checks (2)
assert coverage.barren_files == 0observesmeasure_index_coverageviacoverageassert not coverage.alarmingobservesmeasure_index_coverageviacoverage
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
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 3 requirements
Its run touches their code; that is reach, not proof.
- REQ-DDB-INDEX-002 measured
- REQ-DDB-INDEX-003 measured
- REQ-DDB-INDEX-004 measured