test_synthesize_doxyfile_declares_strip_from_path

Tests › tests/test_build_docs_db.py

passed Passed in the packaged run.

What this test is for

Why it exists

The synthesized driver must strip the repo root from stored paths.

Verifies REQ-DDB-PIPE-001 REQ-DDB-PIPE-010

Given

  1. repo = tmp_path / "myrepo"
  2. repo.mkdir()
→

When

  1. doxyfile = synthesize_doxyfile(repo, tmp_path / "build" / "docs.doxygen")
  2. strip = parse_doxyfile_value(doxyfile, "STRIP_FROM_PATH")
  3. own = tmp_path / "Doxyfile"
2 more
  1. own.write_text("PROJECT_NAME = theirs\n", encoding="utf-8")
  2. _build_doxyfile_content(own, None, None)
→

Then

  1. ✓ strip holds
  2. ✓ Path(strip).is_absolute() holds
  3. ✓ Path(strip) equals repo.resolve()
  4. ✓ _build_doxyfile_content(own, None, None) does not contain "STRIP_FROM_PATH"

tests/test_build_docs_db.py:84 · its file's page

What it checks (4)

  1. assert strip, "the synthesized driver must declare STRIP_FROM_PATH" observes parse_doxyfile_value via strip
  2. assert Path(strip).is_absolute(), "a relative strip prefix resolves against cwd" observes parse_doxyfile_value via strip
  3. assert Path(strip) == repo.resolve(), "the prefix stripped must be the repo root" observes parse_doxyfile_value via strip
  4. assert "STRIP_FROM_PATH" not in _build_doxyfile_content(own, None, None) observes _build_doxyfile_content

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_synthesize_doxyfile_declares_strip_from_path→synthesize_doxyfile→parse_doxyfile_value→_build_doxyfile_content

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_synthesize_doxyfile_declares_strip_from_path · 4 checkssynthesize_doxyfileREQ-DDB-INDEX-001 · measured_build_doxyfile_contentextra_input_clears_excludeREQ-DDB-PIPE-003 · measured

Requirements it verifies (2)

requirementlinked byimplementers exercised
REQ-DDB-PIPE-001catalogunknown
REQ-DDB-PIPE-010catalogunknown
Also reaches 2 requirements

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