source: class ReplyByReturnValueConsumerTest {
  
      private static final MessageEvent EVENT;
      @Rule
      public final MockitoRule mockitoRule;
      @Mock
      private LineMessagingClient lineMessagingClient;
      @InjectMocks
      private ReplyByReturnValueConsumer.Factory targetFactory;
      private ReplyByReturnValueConsumer target;
  
      @Test
      public void errorInCompletableLoggingTest() throws Exception {
  
target:         // Do
          String systemOut = tapSystemOut(() -> {
              final CompletableFuture<List<TextMessage>> returnValue = new CompletableFuture<>();
              target.accept(returnValue);
              returnValue.completeExceptionally(
                      new GeneralLineMessagingException("EXCEPTION HAPPEN!", null, null));
          });
  
          // Verify
          assertThat(systemOut)
                  .contains("EXCEPTION HAPPEN!");
      }
  
  }