Skip to content

Commit 32e650e

Browse files
committed
fix: tests
1 parent b9b21d5 commit 32e650e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

package/src/__tests__/offline-support/optimistic-update.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -767,7 +767,7 @@ export const OptimisticUpdates = () => {
767767

768768
expect(channel.state.messages.some((message) => message.id === localMessage.id)).toBe(true);
769769

770-
jest.spyOn(channel, 'watch').mockImplementation(async () => ({}));
770+
jest.spyOn(channel, 'watch').mockResolvedValue({});
771771

772772
channel.state.removeMessage(localMessage);
773773
channel.state.addMessageSorted(serverMessage, true);
@@ -826,7 +826,7 @@ export const OptimisticUpdates = () => {
826826
pendingTask = pendingTasks[0];
827827
});
828828

829-
jest.spyOn(channel, 'watch').mockImplementation(async () => ({}));
829+
jest.spyOn(channel, 'watch').mockResolvedValue({});
830830

831831
channel.state.removeMessage(localMessage);
832832
await chatClient.offlineDb.deletePendingTask({ id: pendingTask.id });

0 commit comments

Comments
 (0)