From 302adcfa72116305bce4bd32fbe0947c38f26f0c Mon Sep 17 00:00:00 2001 From: e11sy <130844513+e11sy@users.noreply.github.com> Date: Sat, 4 Jan 2025 00:33:12 +0300 Subject: [PATCH] test(notifier-worker): improve readability --- workers/notifier/tests/worker.test.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/workers/notifier/tests/worker.test.ts b/workers/notifier/tests/worker.test.ts index 94dd6787..f6135e95 100644 --- a/workers/notifier/tests/worker.test.ts +++ b/workers/notifier/tests/worker.test.ts @@ -251,10 +251,11 @@ describe('NotifierWorker', () => { worker.sendToSenderWorker = jest.fn(); const message = { ...messageMock }; + message.event.isNew = true; await worker.handle(message); - expect(worker.sendToSenderWorker).toBeCalled(); + expect(worker.sendToSenderWorker).toBeCalledTimes(1); }); it('should send task if event threshold reached', async () => {