From 21bd412fe56905702f30097ce37bf3e9f73ec3d0 Mon Sep 17 00:00:00 2001 From: Jackson Moore Date: Fri, 4 Sep 2026 14:20:00 +0200 Subject: Enforce invalid mapping diagnostic --- tests/run.lua | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'tests') diff --git a/tests/run.lua b/tests/run.lua index 08771db..66816bb 100644 --- a/tests/run.lua +++ b/tests/run.lua @@ -7858,6 +7858,17 @@ test("Free-form action adapter accepts every valid descriptor", function() end end) +test("Free-form action adapter raises the exact invalid mapping error", function() + fresh_sequence_state() + local root = composition_root.new({ host = MemoryHost.new() }) + local ok, diagnostic = pcall(function() + root:invoke_descriptor("X") + end) + + falsy(ok) + same("clever-f: Invalid mapping 'X'", diagnostic) +end) + test("ActionFacade returns typed primary action outcomes", function() fresh_sequence_state() local host = MemoryHost.new({ -- cgit v1.2.3