docs(6209): seventeen more test files — lesson shape and round trip, rule scope/moments/kind/surfacing, drift, deadlock race, backup, inception, backfill, claims, supersession, ledgers, family shapes
CI & Build / Python lint (push) Successful in 2s
CI & Build / Plugin hooks (push) Successful in 13s
CI & Build / TypeScript typecheck (push) Successful in 53s
CI & Build / integration (push) Successful in 1m7s
CI & Build / Python tests (push) Successful in 1m54s
CI & Build / Build & push image (push) Successful in 12s
CI & Build / Python lint (push) Successful in 2s
CI & Build / Plugin hooks (push) Successful in 13s
CI & Build / TypeScript typecheck (push) Successful in 53s
CI & Build / integration (push) Successful in 1m7s
CI & Build / Python tests (push) Successful in 1m54s
CI & Build / Build & push image (push) Successful in 12s
Docstrings and comments state the property and its reason in the present tense. The session-context ledger test no longer describes the decision it "used to pin"; the supersession tests state demote-not-filter without the quote; one-row measurements become the general shape with their figures. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
"""Real-Postgres tests for `rules.kind` and its CHECK (0098, #3849 step 1).
|
||||
"""Real-Postgres tests for `rules.kind` and its CHECK (migration 0098).
|
||||
|
||||
Rule 36 exists because a value and its constraint drift apart: the code
|
||||
A value and its constraint drift apart: the code
|
||||
starts writing a new kind while the database still refuses it, and nothing
|
||||
catches it until a write fails in front of someone. A mock cannot show that —
|
||||
it has no CHECK — so the constraint gets a real-DB test, exactly as 0091's
|
||||
@@ -94,8 +94,7 @@ async def test_an_unknown_kind_is_refused(topic_id):
|
||||
"""The half that proves the constraint is there at all.
|
||||
|
||||
Without this, every other assertion in this file would pass against a
|
||||
table whose CHECK had been dropped — the exact failure rule 36 is written
|
||||
against.
|
||||
table whose CHECK had been dropped — the exact drift this guards.
|
||||
"""
|
||||
_uid, topic = topic_id
|
||||
with pytest.raises(IntegrityError):
|
||||
@@ -119,8 +118,8 @@ async def test_a_rule_can_become_a_preference_after_the_fact(topic_id):
|
||||
"""The read-back is the whole test.
|
||||
|
||||
A version asserting only that the update call succeeded would pass against
|
||||
code that accepted `kind` and dropped it — which is how the same bug
|
||||
survived on `task_kind` long enough to be found by hand (#3129).
|
||||
code that accepted `kind` and dropped it — a bug that otherwise surfaces
|
||||
only when someone finds it by hand.
|
||||
|
||||
This is also the migration path the always-on triage needs: the rules that
|
||||
turn out to be preferences change one column and keep their id, history
|
||||
|
||||
Reference in New Issue
Block a user