test_the_sequence_diagram_is_uml_proper¶
Tests › tests/test_wiki_site.py
What this test is for
Why it exists
numbered steps, and lane heads at top and bottom.
Verifies REQ-DDB-WIKI-011 REQ-DDB-WIKI-012 REQ-DDB-WIKI-013 REQ-DDB-WIKI-014 REQ-DDB-WIKI-015 REQ-DDB-WIKI-018 REQ-DDB-WIKI-020 REQ-DDB-WIKI-021 REQ-DDB-WIKI-022 REQ-DDB-WIKI-023 REQ-DDB-WIKI-025 REQ-DDB-WIKI-031 REQ-DDB-WIKI-044 REQ-DDB-WIKI-050 REQ-DDB-WIKI-052
Given
page = _flow_page(site)start = page.index('<svg class="seq"')svg = page[start : page.index("</svg>", start)]
When
- —
Then
- ✓ svg contains 'class="act"'
- ✓ svg contains 'class="ret"'
- ✓ svg contains 'class="frame"'
- ✓ svg contains ">loop<"
- ✓ re.findall(r'class="num"[^>]*>(\d+)<', svg) equals ["1", "2"]
- ✓ svg contains ">parse<"
- ✓ svg contains ">finish<"
- ✓ svg.count('class="head"') equals 2 * svg.count('class="lane"')
tests/test_wiki_site.py:387 · its file's page
What it checks (5)
assert 'class="act"' in svg and 'class="ret"' in svgnot attributedassert 'class="frame"' in svg and ">loop<" in svgnot attributedassert re.findall(r'class="num"[^>]*>(\d+)<', svg) == ["1", "2"]not attributedassert ">parse<" in svg and ">finish<" in svgnot attributedassert svg.count('class="head"') == 2 * svg.count('class="lane"')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_the_sequence_diagram_is_uml_proper→_flow_pageWhat 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 (15)
| requirement | linked by | implementers exercised |
|---|---|---|
| REQ-DDB-WIKI-011 | catalog | unknown |
| REQ-DDB-WIKI-012 | catalog | unknown |
| REQ-DDB-WIKI-013 | catalog | unknown |
| REQ-DDB-WIKI-014 | catalog | unknown |
| REQ-DDB-WIKI-015 | catalog | unknown |
| REQ-DDB-WIKI-018 | catalog | unknown |
| REQ-DDB-WIKI-020 | catalog | unknown |
| REQ-DDB-WIKI-021 | catalog | unknown |
| REQ-DDB-WIKI-022 | catalog | unknown |
| REQ-DDB-WIKI-023 | catalog | unknown |
| REQ-DDB-WIKI-025 | catalog | unknown |
| REQ-DDB-WIKI-031 | catalog | unknown |
| REQ-DDB-WIKI-044 | catalog | unknown |
| REQ-DDB-WIKI-050 | catalog | unknown |
| REQ-DDB-WIKI-052 | catalog | unknown |