@Test
void publish_new_best_solution_if_all_fact_changes_processed() {

    VehicleRoutingSolution solution = SolutionFactory.emptySolution();
    when(bestSolutionChangedEvent.isEveryProblemFactChangeProcessed()).thenReturn(true);
    when(bestSolutionChangedEvent.getNewBestSolution()).thenReturn(solution);
    solverManager.bestSolutionChanged(bestSolutionChangedEvent);
    verify(routeChangedEventPublisher).publishSolution(solutionArgumentCaptor.capture());
    VehicleRoutingSolution event = solutionArgumentCaptor.getValue();
    assertThat(event).isSameAs(solution);
}