test_two_returns_share_one_definition

Tests › tests/test_wiki_apiref.py

passed Passed in the packaged run.

What this test is for

Why it exists

P6 at 390px (owner Q/A 2026-11-20): an entry with two distinct returns emitted a second `<dd>` with no `<dt>`; the `dl.api-doc` grid put it in the LABEL column, which grew to the sentence's width (844px) and pushed the page sideways. Several returns are one list in one dd.

Verifies REQ-DDB-WIKI-053

Given

  1. —
→

When

  1. html = _doc_lists(Doc(prose="", returns=("A.", "B.")))
→

Then

  1. ✓ html.count("<dd>") == html.count("<dt>") == 1 holds
  2. ✓ html contains "<li>A.</li><li>B.</li>"

tests/test_wiki_apiref.py:456 · its file's page

What it checks (2)

  1. assert html.count("<dd>") == html.count("<dt>") == 1, html observes _doc_lists via html
  2. assert "<li>A.</li><li>B.</li>" in html observes _doc_lists via html

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_two_returns_share_one_definition→_doc_lists

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.

Requirements it verifies (1)

requirementlinked byimplementers exercised
REQ-DDB-WIKI-053catalogunknown