public void waitFor() {
      CountDownLatch waiter = new CountDownLatch(1);
      myQueue.queue(Update.create(waiter, () -> waiter.countDown()));
      ProgressIndicatorUtils.awaitWithCheckCanceled(waiter);
      try {
        myQueue.waitForAllExecuted(10, TimeUnit.SECONDS);
      }
      catch (TimeoutException e) {
        throw new RuntimeException(e);
      }
    }
public void waitFor()