info-tech-canon/tests/test_social_collectives.py
tegwick 3e69bd51b0
All checks were successful
CI Smoke / host-smoke (push) Successful in 0s
CI Smoke / container-smoke (push) Successful in 1s
Extend organization model with distinct social collectives
Assistant: codex
Assistant-Model: gpt-6-astra
Assistant-Session: 01a070b5-4994-7271-bd8b-7c3dbcedec4b
2026-09-05 22:31:15 +02:00

15 lines
829 B
Python

from info_tech_canon.generation import concept_ownership
from info_tech_canon.service import load_context
def test_social_collectives_have_one_owner_and_family_is_not_a_subtype():
context = load_context()
rows = concept_ownership(context)["concepts"]
for concept in ["Community", "Household"]:
assert {r["owner"] for r in rows if r["concept"] == concept} == {"model/organization"}
text = (context.infospace_root / "models/organization/InfoTechCanonOrganizationModel.md").read_text()
taxonomy = text.split("# 9. Root Organization Taxonomy", 1)[1].split("# 10.", 1)[0]
assert "CollectiveActor\n│ ├── Community\n│ └── Household" in taxonomy
assert taxonomy.count("Community") == 1
assert "Family" not in taxonomy
assert "A Household is not a Family" in text