Assume all accounts have primary devices

This commit is contained in:
Jon Chambers
2023-12-05 17:32:49 -05:00
committed by Jon Chambers
parent 69990c23a5
commit 00e72a30c9
11 changed files with 47 additions and 44 deletions

View File

@@ -93,7 +93,7 @@ class PushNotificationManagerTest {
when(device.getId()).thenReturn(Device.PRIMARY_ID);
when(device.getApnId()).thenReturn(deviceToken);
when(account.getDevice(Device.PRIMARY_ID)).thenReturn(Optional.of(device));
when(account.getPrimaryDevice()).thenReturn(device);
when(apnSender.sendNotification(any()))
.thenReturn(CompletableFuture.completedFuture(new SendPushNotificationResult(true, null, false)));