test_code_text_doxygen_stored_verbatim_is_kept_and_structured¶
Tests › tests/test_wiki_apiref.py
What this test is for
Why it exists
ENTROPIC'S AUDIT OF f6ff1f7c (23 entries, 83 of 1,482 include/ descriptions): doxygen stores code text verbatim inside its XML, so `(n_tokens < 2)` or `std::atomic<bool>` made the fragment unparseable. The entry fell back to one flat paragraph with no Parameters or Returns, and the fallback stripped `< 2)` AS A TAG — text lost silently.
Given
xml = ( '<para><parameterlist kind="param"><parameteritem><parameternamelist>' "<parametername>n_tokens</parametername></parameternamelist><parameterdescription>" "<para>Count (fails when n_tokens < 2).</para></parameterdescription></parameteritem>" '</parameterlist><simplesect kind="return"><para>A std::atomic<bool> & a flag.</para>' "</simplesect></para>" )
When
doc = parse_doc(xml)
Then
- ✓ doc.params equals (("n_tokens", "", "Count (fails when n_tokens < 2)."),)
- ✓ doc.returns equals ("A std::atomic<bool> & a flag.",)
tests/test_wiki_apiref.py:399 · its file's page
What it checks (2)
assert doc.params == (("n_tokens", "", "Count (fails when n_tokens < 2)."),)observesparse_docviadocassert doc.returns == ("A std::atomic<bool> & a flag.",)observesparse_docviadoc
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 2 requirements
Its run touches their code; that is reach, not proof.
- REQ-DDB-QUERY-003 inferred
- REQ-DDB-WIKI-053 measured