Fix named reference lookup for long videos

This commit is contained in:
2026-08-31 09:40:51 +00:00
parent a2dabaab7e
commit 130b268d1e
2 changed files with 137 additions and 70 deletions
+14
View File
@@ -513,6 +513,20 @@ class DumasH3LongVideosHelperTests(unittest.TestCase):
["img2", "img4", "img7"],
)
def test_annotate_script_refs_handles_named_characters_and_locations(self):
refs = [
{"kind": "character", "image": "img1", "name": "Mara"},
{"kind": "location", "image": "img2", "name": "Hangar"},
]
report = self.module.annotate_script_refs(
["Mara waits in the Hangar.", "Nobody else is here."],
refs,
)
self.assertIn("# shot 1 refs: Picture 1 Mara (by name); Picture 2 Hangar (by name)", report)
self.assertIn("# shot 2 refs: none", report)
def test_input_types_expose_nine_ref_slots(self):
optional = self.module.H3LongVideos.INPUT_TYPES()["optional"]