Skip to content

Commit

Permalink
test(core): fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
atomrc committed Nov 23, 2021
1 parent cfed987 commit 6fb6659
Showing 1 changed file with 6 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ describe('MessageService', () => {
clientId,
conversationId,
jasmine.any(Object),
undefined,
true,
);
});

Expand All @@ -238,7 +238,7 @@ describe('MessageService', () => {
clientId,
conversationId,
jasmine.any(Object),
undefined,
true,
);
});

Expand All @@ -247,11 +247,7 @@ describe('MessageService', () => {
spyOn(apiClient.broadcast.api, 'postBroadcastMessage').and.returnValue(Promise.resolve({} as ClientMismatch));

await messageService.sendMessage(clientId, generateRecipients(generateUsers(3, 3)), createMessage(message));
expect(apiClient.broadcast.api.postBroadcastMessage).toHaveBeenCalledWith(
clientId,
jasmine.any(Object),
undefined,
);
expect(apiClient.broadcast.api.postBroadcastMessage).toHaveBeenCalledWith(clientId, jasmine.any(Object), true);
});

it('should broadcast protobuf message if no conversationId is given', async () => {
Expand All @@ -267,7 +263,7 @@ describe('MessageService', () => {
expect(apiClient.broadcast.api.postBroadcastProtobufMessage).toHaveBeenCalledWith(
clientId,
jasmine.any(Object),
undefined,
true,
);
});

Expand All @@ -282,7 +278,7 @@ describe('MessageService', () => {
clientId,
conversationId,
jasmine.objectContaining({data: undefined}),
undefined,
true,
);
});

Expand All @@ -303,7 +299,7 @@ describe('MessageService', () => {
clientId,
conversationId,
jasmine.objectContaining({data: jasmine.any(String)}),
undefined,
true,
);
});

Expand Down

0 comments on commit 6fb6659

Please sign in to comment.