feat(client): ContentDB loads canon/ + topics/ built dirs

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HuHRPE7VfppUJEaoGBEUqZ
This commit is contained in:
2026-07-11 18:46:55 -05:00
parent 7ce5e4584c
commit a160d3e967
2 changed files with 24 additions and 0 deletions

View File

@@ -50,3 +50,19 @@ func test_null_quest_ref_resolves():
var o := _deserter()
o["start_quest_id"] = null
assert_eq(db.unresolved_refs(o), [])
func test_loads_canon_and_topics():
assert_true(db.has_canon("town.duncarrow"))
assert_true(db.has_canon("place.the-white-antlers"))
assert_true(db.has_topic("rumor.travelers-go-missing"))
func test_topic_skeleton_has_no_body():
var t: Dictionary = db.topic("secret.crell-runs-slave-trade")
assert_false(t.has("body")) # bodies are server-only
func test_legacy_npcs_still_load():
assert_true(db.has_npc("fenn"))
assert_true(db.has_npc("npc.mera-fenn"))