From 1f2b57fbcdd0746da1050f03fe37a7598eccac50 Mon Sep 17 00:00:00 2001 From: JGerla Date: Sat, 25 Oct 2025 15:34:49 +0200 Subject: [PATCH] chore: updated setupFlowTests.ts to properly handle resetting of the flowState for each test ref: N25B-114 --- test/setupFlowTests.ts | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/test/setupFlowTests.ts b/test/setupFlowTests.ts index b625c03..99920df 100644 --- a/test/setupFlowTests.ts +++ b/test/setupFlowTests.ts @@ -63,7 +63,20 @@ export const mockReactFlow = () => { }); }; -beforeEach(() => { useFlowStore.setState({ nodes: [], edges: [] }); }); +beforeAll(() => { + useFlowStore.setState({ + nodes: [], + edges: [], + edgeReconnectSuccessful: true + }); +}); -afterEach(() => { cleanup(); }); +afterEach(() => { + cleanup(); + useFlowStore.setState({ + nodes: [], + edges: [], + edgeReconnectSuccessful: true + }); +});