test_origin_split_of_classifies_the_three_shapes¶
Tests › tests/test_roster_origin_split.py
What this test is for
Why it exists
`''` is a resolved first-party file, a non-empty string is the owning external root, and `None` is a member with no resolved file. `None` stays its OWN bucket rather than folding into `first_party`, because "we do not know whose this is" is a different claim from "it is ours" — folding them is how a coverage figure comes to look healthier than its evidence.
Given
split = OriginSplit.of(["", "vendor/a", "vendor/a", "vendor/b", None])
When
- —
Then
- ✓ split.total equals 5
- ✓ (split.first_party, split.external, split.unresolved) equals (1, 3, 1)
- ✓ split.external_roots equals ("vendor/a", "vendor/b")
tests/test_roster_origin_split.py:594 · its file's page
What it checks (3)
assert split.total == 5not attributedassert (split.first_party, split.external, split.unresolved) == (1, 3, 1)not attributedassert split.external_roots == ("vendor/a", "vendor/b"), "deduplicated and sorted"not attributed
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 1 requirement
Its run touches their code; that is reach, not proof.
- REQ-DDB-QUERY-011 measured