Skip to content

Commit

Permalink
Update Notification V2 controller tests to align with the new TypeORM…
Browse files Browse the repository at this point in the history
… implementation.
  • Loading branch information
PooyaRaki committed Oct 27, 2024
1 parent 5eae5f2 commit f53fa31
Showing 1 changed file with 16 additions and 4 deletions.
20 changes: 16 additions & 4 deletions src/routes/notifications/v2/notifications.controller.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,10 @@ describe('Notifications Controller V2 (Unit)', () => {
expect(
notificationsRepository.upsertSubscriptions,
).toHaveBeenNthCalledWith(1, {
signerAddress,
authPayload: {
signer_address: signerAddress,
chain_id: authPayloadDto.chain_id,
},
upsertSubscriptionsDto,
});
});
Expand Down Expand Up @@ -247,7 +250,10 @@ describe('Notifications Controller V2 (Unit)', () => {
expect(
notificationsRepository.upsertSubscriptions,
).toHaveBeenNthCalledWith(1, {
signerAddress,
authPayload: {
signer_address: signerAddress,
chain_id: authPayloadDto.chain_id,
},
upsertSubscriptionsDto,
});
});
Expand Down Expand Up @@ -315,7 +321,10 @@ describe('Notifications Controller V2 (Unit)', () => {
expect(
notificationsRepository.upsertSubscriptions,
).toHaveBeenNthCalledWith(1, {
signerAddress,
authPayload: {
signer_address: signerAddress,
chain_id: authPayloadDto.chain_id,
},
upsertSubscriptionsDto,
});
});
Expand Down Expand Up @@ -696,7 +705,10 @@ describe('Notifications Controller V2 (Unit)', () => {
expect(
notificationsRepository.getSafeSubscription,
).toHaveBeenNthCalledWith(1, {
signerAddress,
authPayload: {
chain_id: authPayloadDto.chain_id,
signer_address: authPayloadDto.signer_address,
},
deviceUuid,
chainId,
safeAddress,
Expand Down

0 comments on commit f53fa31

Please sign in to comment.