Skip to content

Commit 939a52f

Browse files
committed
Update tests for NO_CHANGE bug.
1 parent 3cad176 commit 939a52f

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

firebase-config/src/test/java/com/google/firebase/remoteconfig/FirebaseRemoteConfigTest.java

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1160,8 +1160,9 @@ public void realtime_stream_listen_and_failsafe_disabled() throws Exception {
11601160
when(mockFetchHandler.fetch(0)).thenReturn(Tasks.forResult(realtimeFetchedContainerResponse));
11611161
configAutoFetch.listenForNotifications();
11621162

1163-
verify(mockRetryListener).onEvent();
1164-
verify(mockFetchHandler).fetch(0);
1163+
verify(mockListener, never())
1164+
.onError(any(FirebaseRemoteConfigRealtimeUpdateStreamException.class));
1165+
verify(mockFetchHandler).getTemplateVersionNumber();
11651166
}
11661167

11671168
@Test
@@ -1175,9 +1176,9 @@ public void realtimeFetch_defaultTemplateVersion_excludeFetchEtag() throws Excep
11751176
when(mockFetchHandler.getTemplateVersionNumber()).thenReturn(0L);
11761177
when(mockFetchHandler.fetchWithoutEtag(0L))
11771178
.thenReturn(Tasks.forResult(realtimeFetchedContainerResponse));
1178-
configAutoFetch.listenForNotifications();
1179+
configAutoFetch.fetchLatestConfig(0, 1);
11791180

1180-
verify(mockRetryListener).onEvent();
1181+
verify(mockListener).onEvent();
11811182
verify(mockFetchHandler).fetchWithoutEtag(0L);
11821183
}
11831184

0 commit comments

Comments
 (0)