Realign stale thesis tests to the 7-member positioning group

ensure_positioning_framings adds 5 Architect framings to the core
positioning variant group alongside Option A/B, so the group holds 7
candidates and choose_variant retires 6. The two thesis tests still
asserted the pre-framings count of 2 — the tests were stale, not the
seed. Realign them, document the 2+5=7 seed structure in the thesis
guide, and refresh AGENTS.md Current state (13/13 tests green).
This commit is contained in:
Keysat
2026-06-12 18:44:14 -05:00
parent a9611b935b
commit 6816d4a4f0
4 changed files with 17 additions and 8 deletions
+5 -3
View File
@@ -35,12 +35,14 @@ def main():
c = sqlite3.connect(db)
c.row_factory = sqlite3.Row
# choose-variant: pick Option A in the positioning group -> Option B retired
# choose-variant: pick Option A in the positioning group -> every other option retired.
# The group holds Option A/B plus the 5 Architect framings (ensure_positioning_framings) = 7.
opts = c.execute("SELECT id, title FROM thesis_nodes WHERE variant_group='positioning' AND deleted_at IS NULL").fetchall()
check(len(opts) == 2, f"positioning starts with 2 options (got {len(opts)})")
check(len(opts) == 7, f"positioning starts with 7 options: Option A/B + 5 Architect framings (got {len(opts)})")
a = next(o for o in opts if "Option A" in (o["title"] or ""))
res = at.choose_variant(a["id"], db=db)
check(res.get("retired_siblings") == 1, "choose_variant retired the 1 sibling")
expected_retired = len(opts) - 1 # 6: Option B + the 5 framings
check(res.get("retired_siblings") == expected_retired, f"choose_variant retired the {expected_retired} siblings (got {res.get('retired_siblings')})")
live = c.execute("SELECT COUNT(*) FROM thesis_nodes WHERE variant_group='positioning' AND deleted_at IS NULL").fetchone()[0]
check(live == 1, f"positioning now has 1 live option (got {live})")
check(c.execute("SELECT status FROM thesis_nodes WHERE id=?", (a["id"],)).fetchone()[0] == "approved",