(InvocationOnMock invocation)
| 74 | EventLoop eventLoop = Mockito.mock(EventLoop.class); |
| 75 | doAnswer(new Answer<Void>() { |
| 76 | @Override |
| 77 | public Void answer(InvocationOnMock invocation) throws Throwable { |
| 78 | Runnable r = (Runnable) invocation.getArguments()[0]; |
| 79 | r.run(); |
| 80 | return null; |
| 81 | } |
| 82 | }).when(eventLoop).execute(any(Runnable.class)); |
| 83 | when(eventLoop.inEventLoop()).thenReturn(true); |
| 84 | when(channel.eventLoop()).thenReturn(eventLoop); |