@Test
public void handleEvent_should_not_explode_if_eventConverter_explodes() {

    // given
    final Set<Boolean> explosionHappenedContainer = new HashSet<>();
    Function<Integer, String> explodingEventConverter = theInt -> {
        explosionHappenedContainer.add(true);
        throw new RuntimeException("kaboom");
    };
    CircuitBreakerDelegate<Integer, String> badCb =
        new CircuitBreakerDelegate<>(delegateMock, explodingEventConverter);
    CircuitBreaker.ManualModeTask<Integer> badCbManualModeTask = badCb.newManualModeTask();
    // when
    Throwable cbExplosion = catchThrowable(() -> badCbManualModeTask.handleEvent(42));
    // then
    assertThat(explosionHappenedContainer).contains(true);
    verify(delegateManualModeTaskMock, times(0)).handleEvent(anyString());
    assertThat(cbExplosion).isNull();
}