Home
last modified time | relevance | path

Searched refs:mockListener (Results 1 – 10 of 10) sorted by relevance

/external/grpc-grpc-java/core/src/test/java/io/grpc/internal/
DHttp2ClientStreamTransportStateTest.java54 @Mock private ClientStreamListener mockListener; field in Http2ClientStreamTransportStateTest
70 }).when(mockListener).messagesAvailable(Matchers.<StreamListener.MessageProducer>any()); in setUp()
76 state.setListener(mockListener); in transportHeadersReceived_notifiesListener()
83 verify(mockListener, never()).closed(any(Status.class), same(PROCESSED), any(Metadata.class)); in transportHeadersReceived_notifiesListener()
84 verify(mockListener).headersRead(headers); in transportHeadersReceived_notifiesListener()
90 state.setListener(mockListener); in transportHeadersReceived_doesntRequire200()
97 verify(mockListener, never()).closed(any(Status.class), same(PROCESSED), any(Metadata.class)); in transportHeadersReceived_doesntRequire200()
98 verify(mockListener).headersRead(headers); in transportHeadersReceived_doesntRequire200()
104 state.setListener(mockListener); in transportHeadersReceived_noHttpStatus()
111 verify(mockListener, never()).headersRead(any(Metadata.class)); in transportHeadersReceived_noHttpStatus()
[all …]
DAbstractClientStreamTest.java75 @Mock private ClientStreamListener mockListener; field in AbstractClientStreamTest
89 }).when(mockListener).messagesAvailable(Matchers.<StreamListener.MessageProducer>any()); in setUp()
140 stream.start(mockListener); in cancel_notifiesOnlyOnce()
145 verify(mockListener).closed(any(Status.class), same(PROCESSED), any(Metadata.class)); in cancel_notifiesOnlyOnce()
162 stream.start(mockListener); in cantCallStartTwice()
165 stream.start(mockListener); in cantCallStartTwice()
185 stream.start(mockListener); in inboundHeadersReceived_notifiesListener()
189 verify(mockListener).headersRead(headers); in inboundHeadersReceived_notifiesListener()
196 stream.start(mockListener); in inboundHeadersReceived_failsIfStatusReported()
209 stream.start(mockListener); in inboundHeadersReceived_acceptsGzipContentEncoding()
[all …]
DDnsNameResolverTest.java108 private NameResolver.Listener mockListener; field in DnsNameResolverTest
212 resolver.start(mockListener); in resolve_neverCache()
214 verify(mockListener).onAddresses(resultCaptor.capture(), any(Attributes.class)); in resolve_neverCache()
220 verify(mockListener, times(2)).onAddresses(resultCaptor.capture(), any(Attributes.class)); in resolve_neverCache()
244 resolver.start(mockListener); in resolve_cacheForever()
246 verify(mockListener).onAddresses(resultCaptor.capture(), any(Attributes.class)); in resolve_cacheForever()
253 verifyNoMoreInteractions(mockListener); in resolve_cacheForever()
278 resolver.start(mockListener); in resolve_usingCache()
280 verify(mockListener).onAddresses(resultCaptor.capture(), any(Attributes.class)); in resolve_usingCache()
288 verifyNoMoreInteractions(mockListener); in resolve_usingCache()
[all …]
DServerImplTest.java1106 ServerStreamListener mockListener = mock(ServerStreamListener.class); in messageRead_errorCancelsCall() local
1107 listener.setListener(mockListener); in messageRead_errorCancelsCall()
1110 doThrow(expectedT).when(mockListener) in messageRead_errorCancelsCall()
1131 ServerStreamListener mockListener = mock(ServerStreamListener.class); in messageRead_runtimeExceptionCancelsCall() local
1132 listener.setListener(mockListener); in messageRead_runtimeExceptionCancelsCall()
1135 doThrow(expectedT).when(mockListener) in messageRead_runtimeExceptionCancelsCall()
1156 ServerStreamListener mockListener = mock(ServerStreamListener.class); in halfClosed_errorCancelsCall() local
1157 listener.setListener(mockListener); in halfClosed_errorCancelsCall()
1160 doThrow(expectedT).when(mockListener).halfClosed(); in halfClosed_errorCancelsCall()
1179 ServerStreamListener mockListener = mock(ServerStreamListener.class); in halfClosed_runtimeExceptionCancelsCall() local
[all …]
DManagedChannelImplTest.java1808 ClientCall.Listener<Integer> mockListener = in verifyPanicMode() local
1812 call.start(mockListener, new Metadata()); in verifyPanicMode()
1814 verifyCallListenerClosed(mockListener, Status.Code.INTERNAL, cause); in verifyPanicMode()
/external/deqp/android/cts/runner/tests/src/com/drawelements/deqp/runner/
DDeqpTestRunnerTest.java218 ITestInvocationListener mockListener in testGlesVersion() local
253 mockListener.testRunStarted(getTestId(deqpTest), 1); in testGlesVersion()
256 mockListener.testStarted(EasyMock.eq(testId)); in testGlesVersion()
259 mockListener.testEnded(EasyMock.eq(testId), EasyMock.<HashMap<String, Metric>>notNull()); in testGlesVersion()
262 mockListener.testRunEnded(EasyMock.anyLong(), EasyMock.<HashMap<String, Metric>>notNull()); in testGlesVersion()
266 EasyMock.replay(mockListener); in testGlesVersion()
269 deqpTest.run(mockListener); in testGlesVersion()
271 EasyMock.verify(mockListener); in testGlesVersion()
354 ITestInvocationListener mockListener in testResultCode() local
379 mockListener.testRunStarted(getTestId(deqpTest), 1); in testResultCode()
[all …]
/external/robolectric-shadows/robolectric/src/test/java/org/robolectric/shadows/
DShadowTextToSpeechTest.java27 private UtteranceProgressListener mockListener; field in ShadowTextToSpeechTest
37 mockListener = mock(UtteranceProgressListener.class); in setUp()
113 textToSpeech.setOnUtteranceProgressListener(mockListener); in threeArgumentSpeak_withUtteranceId_shouldGetCallbackUtteranceId()
120 verify(mockListener).onStart("ThreeArgument"); in threeArgumentSpeak_withUtteranceId_shouldGetCallbackUtteranceId()
121 verify(mockListener).onDone("ThreeArgument"); in threeArgumentSpeak_withUtteranceId_shouldGetCallbackUtteranceId()
126 textToSpeech.setOnUtteranceProgressListener(mockListener); in threeArgumentSpeak_withoutUtteranceId_shouldDoesNotGetCallback()
131 verify(mockListener, never()).onStart(null); in threeArgumentSpeak_withoutUtteranceId_shouldDoesNotGetCallback()
132 verify(mockListener, never()).onDone(null); in threeArgumentSpeak_withoutUtteranceId_shouldDoesNotGetCallback()
145 textToSpeech.setOnUtteranceProgressListener(mockListener); in onUtteranceProgressListener_shouldGetCallbackUtteranceId()
150 verify(mockListener).onStart("TTSEnable"); in onUtteranceProgressListener_shouldGetCallbackUtteranceId()
[all …]
DShadowSharedPreferencesTest.java173 …SharedPreferences.OnSharedPreferenceChangeListener mockListener = mock(SharedPreferences.OnSharedP… in shouldRemoveRegisteredListenersOnUnresgister() local
174 anotherSharedPreferences.registerOnSharedPreferenceChangeListener(mockListener); in shouldRemoveRegisteredListenersOnUnresgister()
176 anotherSharedPreferences.unregisterOnSharedPreferenceChangeListener(mockListener); in shouldRemoveRegisteredListenersOnUnresgister()
179 verifyZeroInteractions(mockListener); in shouldRemoveRegisteredListenersOnUnresgister()
DShadowWifiP2pManagerTest.java24 @Mock private WifiP2pManager.ChannelListener mockListener; field in ShadowWifiP2pManagerTest
33 channel = manager.initialize(context, context.getMainLooper(), mockListener); in setUp()
/external/grpc-grpc-java/services/src/test/java/io/grpc/services/
DBinlogHelperTest.java850 ClientCall.Listener<byte[]> mockListener = mock(ClientCall.Listener.class); in clientDeadlineLogged_deadlineSetViaCallOption() local
871 call.start(mockListener, new Metadata()); in clientDeadlineLogged_deadlineSetViaCallOption()
924 ClientCall.Listener<byte[]> mockListener = mock(ClientCall.Listener.class); in clientDeadlineLogged_deadlineSetViaContext() local
925 callFuture.get().start(mockListener, new Metadata()); in clientDeadlineLogged_deadlineSetViaContext()
977 ClientCall.Listener<byte[]> mockListener = mock(ClientCall.Listener.class); in clientInterceptor() local
997 interceptedCall.start(mockListener, clientInitial); in clientInterceptor()
1026 verify(mockListener).onHeaders(same(serverInitial)); in clientInterceptor()
1056 verify(mockListener).onMessage(same(response)); in clientInterceptor()
1072 verify(mockListener).onClose(same(status), same(trailers)); in clientInterceptor()
1082 final ServerCall.Listener mockListener = mock(ServerCall.Listener.class); in serverInterceptor() local
[all …]