// Check possible routes
for (Itinerary itinerary : routeCandidates)
{
assertThat( "First load location equals origin location.",
itinerary.firstLeg().loadLocation().get(),
is( equalTo( cargo.routeSpecification().get().origin().get() ) ) );
assertThat( "Last unload location equals destination location.",
itinerary.lastLeg().unloadLocation().get(),
is( equalTo( cargo.routeSpecification().get().destination().get() ) ) );
assertThat( "Cargo will be delivered in time.",
itinerary.finalArrivalDate().before( cargo.routeSpecification().get().arrivalDeadline().get() ),