From 7c0b8bee70ad2c4f4f4ca10a867f9878febc5248 Mon Sep 17 00:00:00 2001 From: Julius Marminge Date: Sun, 1 Mar 2026 19:18:46 -0800 Subject: [PATCH] Cover runtime undefined draft thread options in store test - Build options object with runtime `undefined` values via cast - Pass object into `setProjectDraftThreadId` to verify handling path --- apps/web/src/composerDraftStore.test.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/apps/web/src/composerDraftStore.test.ts b/apps/web/src/composerDraftStore.test.ts index c2dd5c1240..c994fcb79f 100644 --- a/apps/web/src/composerDraftStore.test.ts +++ b/apps/web/src/composerDraftStore.test.ts @@ -282,10 +282,14 @@ describe("composerDraftStore project draft thread mapping", () => { branch: "main", worktreePath: "/tmp/main-worktree", }); - store.setProjectDraftThreadId(projectId, threadId, { + const runtimeUndefinedOptions = { branch: undefined, worktreePath: undefined, - }); + } as unknown as { + branch?: string | null; + worktreePath?: string | null; + }; + store.setProjectDraftThreadId(projectId, threadId, runtimeUndefinedOptions); expect(useComposerDraftStore.getState().getDraftThread(threadId)).toMatchObject({ projectId,