@Test
void shouldConvertRunningNettyFutureToCompletionStageWhenFutureFailed() throws Exception
{

    RuntimeException error = new RuntimeException( "Hello" );
    DefaultPromise<String> promise = new DefaultPromise<>( ImmediateEventExecutor.INSTANCE );
    CompletableFuture<String> future = Futures.asCompletionStage( promise ).toCompletableFuture();
    assertFalse( future.isDone() );
    promise.setFailure( error );
    assertTrue( future.isCompletedExceptionally() );
    ExecutionException e = assertThrows( ExecutionException.class, future::get );
    assertEquals( error, e.getCause() );
}