From 44aa676fa5cee4cc4b8e36029f15320f7bd6ab8c Mon Sep 17 00:00:00 2001 From: majdyz Date: Sun, 12 Apr 2026 12:09:06 +0000 Subject: [PATCH] fix(frontend): update stale assertion in applyConnectNodes duplicate-edge test After the double-call fix removed the direct setAppliedActionKeys call from the alreadyExists branch, the test still expected it to be called once. Updated to .not.toHaveBeenCalled() since the caller (handleApplyAction) now handles marking applied keys. --- .../BuilderChatPanel/__tests__/actionApplicators.test.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/autogpt_platform/frontend/src/app/(platform)/build/components/BuilderChatPanel/__tests__/actionApplicators.test.ts b/autogpt_platform/frontend/src/app/(platform)/build/components/BuilderChatPanel/__tests__/actionApplicators.test.ts index 30b30ea9d6..ca190b97f0 100644 --- a/autogpt_platform/frontend/src/app/(platform)/build/components/BuilderChatPanel/__tests__/actionApplicators.test.ts +++ b/autogpt_platform/frontend/src/app/(platform)/build/components/BuilderChatPanel/__tests__/actionApplicators.test.ts @@ -579,9 +579,9 @@ describe("applyConnectNodes", () => { deps, ); expect(result).toBe(true); - // No new edge written; applied key still marked. + // No new edge written; caller (handleApplyAction) marks the key. expect(mockSetEdges).not.toHaveBeenCalled(); - expect(deps.setAppliedActionKeys).toHaveBeenCalledTimes(1); + expect(deps.setAppliedActionKeys).not.toHaveBeenCalled(); // No undo entry for a no-op. expect(deps.setUndoStack).not.toHaveBeenCalled(); });