@Test
void scheduleTriggerTask() {

    ZonedDateTime now = ZonedDateTime.now();
    scheduler.clock = Clock.fixed(now.toInstant(), ZoneId.systemDefault());
    var task = new TriggerTask("trigger-job", null, previous -> previous.plusHours(1), ZoneId.systemDefault());
    scheduler.schedule(task, now);
    ArgumentCaptor<Runnable> scheduledTask = ArgumentCaptor.forClass(Runnable.class);
    verify(schedulerExecutor).schedule(scheduledTask.capture(), eq(0L), eq(TimeUnit.NANOSECONDS));
    scheduledTask.getValue().run();
    verify(schedulerExecutor).schedule(scheduledTask.capture(), eq(Duration.ofHours(1).toNanos()), eq(TimeUnit.NANOSECONDS));
    verify(jobExecutor).submit((Callable<?>) any(Callable.class));
}