MessageResponseListener extends MessageListener implements Disposable { @Override public void dispose() { responses.dispose(); } MessageResponseListener( Messenger messenger ); @Override void dispose(); MessageResponse waitResponse( MessageRequest request, int requestTimeout, int responseTimeout ); @Override void onMessage( final Message message );  }
@Test public void testDispose() throws Exception { listener.dispose(); verify( responses ).dispose(); }