@Test
public void testThenAcceptBoth() throws InterruptedException {

    CompletionStage<Void> firstCompletionStage = Async.supplyAsync(latchSupplier(latch1), executorA);
    latch1.countDown();
    firstCompletionStage.toCompletableFuture().join();
    assertHits(executorA, 1);
    
    BiConsumer<Void, Void> bc = (Void x, Void y) -> {};
    CompletionStage<Void> secondCompletionStage = firstCompletionStage.thenAcceptBoth(completedFuture(), bc);
    secondCompletionStage.toCompletableFuture().join();
    assertHits(executorA, 1);
    
    BiConsumer<Void, Void> bf2 = Unchecked.biConsumer((Void x, Void y) -> {latch2.await();});
    CompletionStage<Void> thirdCompletionStage = secondCompletionStage.thenAcceptBothAsync(completedFuture(), bf2);
    latch2.countDown();
    thirdCompletionStage.toCompletableFuture().join();
    assertHits(executorA, 2);
    
    BiConsumer<Void, Void> bf3 = Unchecked.biConsumer((Void x, Void y) -> {latch3.await();});
    CompletionStage<Void> fourthCompletionStage = thirdCompletionStage.thenAcceptBothAsync(completedFuture(), bf3, executorB);
    latch3.countDown();
    fourthCompletionStage.toCompletableFuture().join();
    assertHits(executorA, 2);
    assertHits(executorB, 1);
}