Skip to content

Commit 895ffdb

Browse files
test(mobile): the unpin-undo table decides the snooze case from its literal, not Date.now()
Co-Authored-By: Claude Fable 5.1 <[email protected]>
1 parent 41f3d37 commit 895ffdb

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

‎apps/mobile/src/features/home/useThreadListActions.test.ts‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -391,7 +391,8 @@ describe("thread action undo", () => {
391391
await useThreadListActions().unpinThread(thread);
392392
expect(readThreadUndoNotice()?.action).toBe("Unpinned");
393393
await readThreadUndoNotice()!.undo();
394-
const restoresSnooze = snoozedUntil != null && Date.parse(snoozedUntil) > Date.now();
394+
// 2099 is the unexpired case; 2000 has long passed.
395+
const restoresSnooze = snoozedUntil === "2099-01-01T09:00:00.000Z";
395396
expect(state.requests.map(({ action }) => action)).toEqual(
396397
restoresSnooze ? ["unpin", "pin", "snooze"] : ["unpin", "pin"],
397398
);

0 commit comments

Comments
 (0)