@Test
public void testDoFormatNewAction() {

    Schedule firstCompleted = updateStatus(REFERENCE_SCHEDULE, newSchedulingStatus(SchedulingState.Succeeded));
    Schedule nextAction = firstCompleted.toBuilder()
            .withCurrentAction(ScheduledAction.newBuilder()
                    .withId("reference")
                    .withStatus(newSchedulingStatus(SchedulingState.Waiting))
                    .withIteration(ExecutionId.initial())
                    .build()
            )
            .withCompletedActions(Collections.singletonList(firstCompleted.getCurrentAction()))
            .build();
    verify(LocalSchedulerTransactionLogger.doFormat(new ScheduleUpdateEvent(nextAction)));
}