- public void busConsumerFailTest() throws MalformedURLException, MRApiException{
- new BusConsumer.DmaapConsumerWrapper(Arrays.asList("test"), "test", "test", "test", "test", "test", 1, 1).fetch();
+ public void busConsumerFailTest() throws Exception {
+ //given
+ MRConsumerImpl mrConsumer = mock(MRConsumerImpl.class);
+ when(mrConsumer.fetch()).thenThrow(new Exception());
+ DmaapConsumerWrapper dmaapConsumerWrapper = new DmaapConsumerWrapper(mrConsumer, "", "", "");
+
+ //when
+ dmaapConsumerWrapper.fetch();