test_a_covered_family_is_not_reported¶
Tests › tests/test_diagnostics.py
What this test is for
Why it exists
The diagnostic names what is NOT covered, so declaring the prefix must silence it. Without this the payload would be a list of every accessor family in the repo, which would say nothing about what is missing — and would keep saying it after an operator fixed the thing it complained about.
Given
db = _corpus( tmp_path / "clew.db", [("macro definition", f"Store_Set_{key}") for key in ("A", "B", "C", "D", "E")], )covering = NamePrefixPattern("Store_Set_")
When
bare = dg.collect(db, tmp_path / "absent.Doxyfile", None, None, None)conn = sqlite3.connect(f"file:{db}?mode=ro", uri=True)try: from clew.shared_key_edges import detect_undeclared_accessor_families assert detect_undeclared_accessor_families(conn, [covering]) == [] finally: conn.close()
Then
- ✓ bare.as_meta()["accessor_families_count"] equals "1"
tests/test_diagnostics.py:334 · its file's page
What it checks (2)
assert bare.as_meta()["accessor_families_count"] == "1", "control: undeclared, so reported"observescollectviabareassert detect_undeclared_accessor_families(conn, [covering]) == []observesdetect_undeclared_accessor_families
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 7 requirements
Its run touches their code; that is reach, not proof.
- REQ-DDB-CONFIG-006 measured
- REQ-DDB-CONFIG-007 measured
- REQ-DDB-QUERY-011 measured
- REQ-DDB-SCHEMA-001 measured
- REQ-DDB-SCHEMA-005 measured
- REQ-DDB-SCHEMA-011 measured
- REQ-DDB-SCHEMA-012 measured