From b8aea50dfa6d4400afaea85904ae88ac2b5fbd5d Mon Sep 17 00:00:00 2001 From: YeonGyu-Kim Date: Wed, 11 Mar 2026 20:15:16 +0900 Subject: [PATCH] test(background-agent): update completion timer test for per-task cleanup Test expected timers only after allComplete, but H2 fix intentionally decoupled per-task cleanup from sibling completion state. Updated assertion to expect timer after individual task notification. --- src/features/background-agent/manager.test.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/features/background-agent/manager.test.ts b/src/features/background-agent/manager.test.ts index d4a1244d6..67ddd8b44 100644 --- a/src/features/background-agent/manager.test.ts +++ b/src/features/background-agent/manager.test.ts @@ -3785,7 +3785,7 @@ describe("BackgroundManager.completionTimers - Memory Leak Fix", () => { manager.shutdown() }) - test("should start cleanup timers only after all tasks complete", async () => { + test("should start per-task cleanup timers independently of sibling completion", async () => { // given const client = { session: { @@ -3832,7 +3832,7 @@ describe("BackgroundManager.completionTimers - Memory Leak Fix", () => { // then const completionTimers = getCompletionTimers(manager) - expect(completionTimers.size).toBe(0) + expect(completionTimers.size).toBe(1) // when await (manager as unknown as { notifyParentSession: (task: BackgroundTask) => Promise })