File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
OneSignalSDK/unittest/src/test/java/com/test/onesignal Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -440,7 +440,12 @@ public void testAfterLastInAppTimeIsDisplayedOncePerSession() throws Exception {
440
440
.pollInterval (new Duration (100 , TimeUnit .MILLISECONDS ))
441
441
.untilAsserted (() -> {
442
442
assertEquals (1 , OneSignalPackagePrivateHelper .getInAppMessageDisplayQueue ().size ());
443
- assertEquals (message2 .messageId , OneSignalPackagePrivateHelper .getShowingInAppMessageId ());
443
+ try {
444
+ assertEquals (message2 .messageId , OneSignalPackagePrivateHelper .getShowingInAppMessageId ());
445
+ } catch (NullPointerException e ) {
446
+ // Awaitility won't retry if something is thrown, but will if an assert fails.
447
+ fail ("Should not throw" );
448
+ }
444
449
});
445
450
446
451
You can’t perform that action at this time.
0 commit comments