// TODO: The timings here will be inaccurate on slow systems.
@Test
  void buildTask() throws Exception {
    VelocityScheduler scheduler = new VelocityScheduler(new FakePluginManager());
    CountDownLatch latch = new CountDownLatch(1);
    ScheduledTask task = scheduler.buildTask(FakePluginManager.PLUGIN_A, latch::countDown)
        .schedule();
    latch.await();
    assertEquals(TaskStatus.FINISHED, task.status());
  }
@Test
void buildTask() throws Exception {
VelocityScheduler scheduler = new VelocityScheduler(new FakePluginManager());
CountDownLatch latch = new CountDownLatch(1);
ScheduledTask task = scheduler.buildTask(FakePluginManager.PLUGIN_A, latch::countDown)
.schedule();
latch.await();
assertEquals(TaskStatus.FINISHED, task.status());
}
@Test
void buildTask() throws Exception {
VelocityScheduler scheduler = new VelocityScheduler(new FakePluginManager());
CountDownLatch latch = new CountDownLatch(1);
ScheduledTask task = scheduler.buildTask(FakePluginManager.PLUGIN_A, latch::countDown)
.schedule();
latch.await();
assertEquals(TaskStatus.FINISHED, task.status());
}
@Test
void buildTask() throws Exception {
VelocityScheduler scheduler = new VelocityScheduler(new FakePluginManager());
CountDownLatch latch = new CountDownLatch(1);
ScheduledTask task = scheduler.buildTask(FakePluginManager.PLUGIN_A, latch::countDown)
.schedule();
latch.await();
assertEquals(TaskStatus.FINISHED, task.status());
}