test_declared_wrapper_merges_over_the_builtin_primitives¶
Tests › tests/test_locks.py
What this test is for
Why it exists
The built-ins are language/OS primitives. A project's OWN guard type is DECLARED, never guessed — and declaring one must not drop the defaults.
Given
- —
When
patterns = load_lock_patterns({"locks": [{"name": "ScopedLock", "form": "raii"}]})names = {p.name for p in patterns}
Then
- ✓ names contains "ScopedLock"
- ✓ {p.name for p in DEFAULT_LOCK_PATTERNS} is at most names
tests/test_locks.py:189 · its file's page
What it checks (2)
assert "ScopedLock" in namesnot attributedassert {p.name for p in DEFAULT_LOCK_PATTERNS} <= namesnot 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
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-SCHEMA-011 measured
- REQ-DDB-SCHEMA-012 measured