test_a_RELATIVE_qualifier_still_resolves¶
Tests › tests/test_ast_recovery.py
What this test is for
Why it exists
C++ lets a call site qualify relative to its enclosing namespace: inside `namespace entropic`, `mcp::sanitize_utf8()` names `entropic::mcp::sanitize_utf8`. On the public entropic index this is not a corner case — 92 of 662 matchable qualified sites take the relative form, including `detail::parse_range_header` (19) and `mcp::sanitize_utf8` (12).
Given
resolved: list[tuple[int, int, str]] = []fuzzy: list[tuple[int, int, str]] = []
When
_ast_record_call_edge( 1, "sanitize_utf8", {"sanitize_utf8": [40, 41]}, resolved, fuzzy, "ast_member", qualified="mcp::sanitize_utf8", definition_of={ 40: "std::string entropic::mcp::sanitize_utf8(const std::string &)", 41: "std::string other::text::sanitize_utf8(const char *)", }, )
Then
- ✓ resolved equals [(1, 40, "ast_member")]
- ✓ fuzzy equals []
tests/test_ast_recovery.py:249 · its file's page
What it checks (2)
assert resolved == [(1, 40, "ast_member")], ( "a relative qualifier must resolve through the enclosing namespace" )not attributedassert fuzzy == []not attributed
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_a_RELATIVE_qualifier_still_resolves→_ast_record_call_edgeWhat 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 1 requirement
Its run touches their code; that is reach, not proof.
- REQ-DDB-WIKI-054 inferred