chore: updated setupFlowTests.ts to properly handle resetting of the flowState for each test

ref: N25B-114
This commit is contained in:
JGerla
2025-10-25 15:34:49 +02:00
parent 2e2bd587d0
commit 1f2b57fbcd

View File

@@ -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
});
});