### Question:
DefaultCompletableAsyncCompletion implements CompletableAsyncCompletion { @Override public AsyncCompletion thenScheduleRun(Vertx vertx, Runnable runnable) { requireNonNull(vertx); requireNonNull(runnable); CompletableAsyncCompletion completion = AsyncCompletion.incomplete(); future.whenComplete((t, ex1) -> { if (ex1 == null) { try { vertx.runOnContext(ev -> { try { runnable.run(); } catch (Throwable ex3) { completion.completeExceptionally(ex3); return; } completion.complete(); }); } catch (Throwable ex2) { completion.completeExceptionally(ex2); } } else { completion.completeExceptionally(ex1); } }); return completion; } DefaultCompletableAsyncCompletion();   DefaultCompletableAsyncCompletion(CompletableFuture<Void> future); @Override boolean complete(); @Override boolean completeExceptionally(Throwable ex); @Override boolean cancel(); @Override boolean isDone(); @Override boolean isCompletedExceptionally(); @Override boolean isCancelled(); @Override void join(); @Override void join(long timeout, TimeUnit unit); @Override AsyncResult<U> then(Supplier<? extends AsyncResult<U>> fn); @Override AsyncResult<U> thenSchedule(Vertx vertx, Supplier<? extends AsyncResult<U>> fn); @Override AsyncCompletion thenCompose(Supplier<? extends AsyncCompletion> fn); @Override AsyncCompletion thenRun(Runnable action); @Override AsyncCompletion thenScheduleRun(Vertx vertx, Runnable runnable); @Override AsyncCompletion thenScheduleBlockingRun(Vertx vertx, Runnable runnable); @Override AsyncCompletion thenScheduleBlockingRun(WorkerExecutor executor, Runnable runnable); @Override AsyncResult<U> thenSupply(Supplier<? extends U> supplier); @Override AsyncResult<U> thenSupply(Vertx vertx, Supplier<? extends U> supplier); @Override AsyncCompletion thenConsume(AsyncResult<? extends U> other, Consumer<? super U> consumer); @Override AsyncResult<V> thenApply(AsyncResult<? extends U> other, Function<? super U, ? extends V> fn); @Override AsyncCompletion thenCombine(AsyncCompletion other); @Override AsyncCompletion exceptionally(Consumer<? super Throwable> consumer); @Override AsyncCompletion whenComplete(Consumer<? super Throwable> consumer); @Override AsyncResult<U> handle(Function<? super Throwable, ? extends U> fn); @Override AsyncCompletion accept(Consumer<? super Throwable> consumer); @Override CompletableFuture<Void> toFuture();  }### Answer:
@Test void thenScheduleRun(@VertxInstance Vertx vertx) throws Exception { CompletableAsyncCompletion completion = AsyncCompletion.incomplete(); AtomicReference<Boolean> ref = new AtomicReference<>(); AsyncCompletion after = completion.thenScheduleRun(vertx, () -> ref.set(true)); completion.complete(); after.join(); assertThat(ref.get()).isTrue(); }