Home
last modified time | relevance | path

Searched refs:mockHandler (Results 1 – 8 of 8) sorted by relevance

/external/grpc-grpc-java/alts/src/test/java/io/grpc/alts/internal/
DGoogleDefaultProtocolNegotiatorTest.java53 GrpcHttp2ConnectionHandler mockHandler = mock(GrpcHttp2ConnectionHandler.class); in altsHandler() local
54 when(mockHandler.getEagAttributes()).thenReturn(eagAttributes); in altsHandler()
55 Handler handler = googleProtocolNegotiator.newHandler(mockHandler); in altsHandler()
56 verify(altsProtocolNegotiator, times(1)).newHandler(mockHandler); in altsHandler()
57 verify(tlsProtocolNegotiator, never()).newHandler(mockHandler); in altsHandler()
63 GrpcHttp2ConnectionHandler mockHandler = mock(GrpcHttp2ConnectionHandler.class); in tlsHandler() local
64 when(mockHandler.getEagAttributes()).thenReturn(eagAttributes); in tlsHandler()
65 Handler handler = googleProtocolNegotiator.newHandler(mockHandler); in tlsHandler()
66 verify(altsProtocolNegotiator, never()).newHandler(mockHandler); in tlsHandler()
67 verify(tlsProtocolNegotiator, times(1)).newHandler(mockHandler); in tlsHandler()
/external/mockito/src/main/java/org/mockito/internal/handler/
DInvocationNotifierHandler.java26 private final MockHandler<T> mockHandler; field in InvocationNotifierHandler
28 public InvocationNotifierHandler(MockHandler<T> mockHandler, MockCreationSettings<T> settings) { in InvocationNotifierHandler() argument
29 this.mockHandler = mockHandler; in InvocationNotifierHandler()
35 Object returnedValue = mockHandler.handle(invocation); in handle()
66 return mockHandler.getMockSettings(); in getMockSettings()
70 return mockHandler.getInvocationContainer(); in getInvocationContainer()
/external/slf4j/slf4j-jdk14/src/test/java/org/slf4j/impl/
DJDK14AdapterLoggerNameTest.java34 private MockHandler mockHandler; field in JDK14AdapterLoggerNameTest
39 mockHandler = new MockHandler(); in setUp()
41 logger.addHandler(mockHandler); in setUp()
71 assertNotNull("no log record", mockHandler.record); in assertCorrectLoggerName()
72 assertNotNull("missing logger name", mockHandler.record.getLoggerName()); in assertCorrectLoggerName()
/external/mockito/src/test/java/org/mockito/internal/handler/
DInvocationNotifierHandlerTest.java47 @Mock private MockHandlerImpl<ArrayList<Answer<?>>> mockHandler; field in InvocationNotifierHandlerTest
54 mockHandler, in setUp()
62 given(mockHandler.handle(invocation)).willReturn("returned value"); in should_notify_all_listeners_when_calling_delegate_handler()
76 given(mockHandler.handle(invocation)).willReturn(computedException); in should_notify_all_listeners_when_called_delegate_handler_returns_ex()
90 given(mockHandler.handle(invocation)).willThrow(parseException); in should_notify_all_listeners_when_called_delegate_handler_throws_exception_and_rethrow_it()
124 verify(mockHandler).getInvocationContainer(); in should_delegate_all_MockHandlerInterface_to_the_parameterized_MockHandler()
125 verify(mockHandler).getMockSettings(); in should_delegate_all_MockHandlerInterface_to_the_parameterized_MockHandler()
/external/mockito/src/main/java/org/mockito/internal/util/
DDefaultMockingDetails.java52 return mockHandler().getMockSettings(); in getMockCreationSettings()
68 return mockHandler(); in getMockHandler()
76 private MockHandler<Object> mockHandler() { in mockHandler() method in DefaultMockingDetails
DMockUtil.java33 MockHandler mockHandler = createMockHandler(settings); in createMock() local
35 T mock = mockMaker.createMock(settings, mockHandler); in createMock()
/external/grpc-grpc-java/netty/src/test/java/io/grpc/netty/
DProtocolNegotiatorsTest.java321 ChannelInboundHandler mockHandler = mock(ChannelInboundHandler.class); in httpProxy_completes() local
323 .childHandler(mockHandler) in httpProxy_completes()
342 Mockito.verify(mockHandler).channelActive(contextCaptor.capture()); in httpProxy_completes()
351 Mockito.verify(mockHandler) in httpProxy_completes()
366 Mockito.verify(mockHandler, times(2)) in httpProxy_completes()
385 ChannelInboundHandler mockHandler = mock(ChannelInboundHandler.class); in httpProxy_500() local
387 .childHandler(mockHandler) in httpProxy_500()
406 Mockito.verify(mockHandler).channelActive(contextCaptor.capture()); in httpProxy_500()
415 Mockito.verify(mockHandler) in httpProxy_500()
/external/robolectric-shadows/robolectric/src/test/java/org/robolectric/shadows/
DShadowInputMethodManagerTest.java77 ShadowInputMethodManager.SoftInputVisibilityChangeHandler mockHandler = in shouldNotifyHandlerWhenVisibilityChanged() local
79 shadow.setSoftInputVisibilityHandler(mockHandler); in shouldNotifyHandlerWhenVisibilityChanged()
83 verify(mockHandler).handleSoftInputVisibilityChange(true); in shouldNotifyHandlerWhenVisibilityChanged()