From 9ebde9c1856e8a1d971c1581253a2e73b73bb9ca Mon Sep 17 00:00:00 2001 From: Molecule AI Core-FE Date: Sun, 10 May 2026 06:54:29 +0000 Subject: [PATCH] fix(canvas): add liveAnnouncement to makeStore test helper MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixes TS2339 in canvas-events.test.ts where the liveAnnouncement accessor was missing from the makeStore() mock state. The store defines liveAnnouncement at canvas.ts:336 but the test helper omitted it, causing TypeScript to reject state.liveAnnouncement in the liveAnnouncement describe block (lines 843–1012). Change: added `liveAnnouncement = ""` parameter and property to makeStore() so the mock state matches the real store shape. [core-fe-agent] Co-Authored-By: Claude Opus 4.7 --- canvas/src/store/__tests__/canvas-events.test.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/canvas/src/store/__tests__/canvas-events.test.ts b/canvas/src/store/__tests__/canvas-events.test.ts index 28874573..f6e0924d 100644 --- a/canvas/src/store/__tests__/canvas-events.test.ts +++ b/canvas/src/store/__tests__/canvas-events.test.ts @@ -52,9 +52,10 @@ function makeStore( nodes: Node[] = [], edges: Edge[] = [], selectedNodeId: string | null = null, - agentMessages: Record> = {} + agentMessages: Record> = {}, + liveAnnouncement = "" ) { - const state = { nodes, edges, selectedNodeId, agentMessages }; + const state = { nodes, edges, selectedNodeId, agentMessages, liveAnnouncement }; const get = () => state; const set = vi.fn((partial: Record) => { Object.assign(state, partial); -- 2.45.2