fixing unit tests

This commit is contained in:
Moritz Kobitzsch
2016-04-06 16:47:16 +02:00
parent fa0a5040e5
commit dfd180a292
11 changed files with 134 additions and 116 deletions
+1 -1
View File
@@ -67,7 +67,7 @@ inline RouteLeg assembleLeg(const std::vector<PathData> &route_data,
{
duration -= (target_traversed_in_reverse ? source_node.reverse_weight
: source_node.forward_weight) /
10;
10.0;
}
return RouteLeg{duration, distance, {}};
+3 -1
View File
@@ -128,9 +128,11 @@ std::vector<RouteStep> assembleSteps(const DataFacadeT &facade,
// This step has length zero, the only reason we need it is the target location
auto final_maneuver = detail::stepManeuverFromGeometry(
extractor::guidance::TurnInstruction::NO_TURN(), WaypointType::Arrive, leg_geometry);
BOOST_ASSERT(!leg_geometry.locations.empty());
steps.push_back(RouteStep{target_node.name_id, facade.GetNameForID(target_node.name_id),
NO_ROTARY_NAME, ZERO_DURATION, ZERO_DISTANCE, target_mode,
final_maneuver, leg_geometry.locations.size(),
final_maneuver, leg_geometry.locations.size()-1,
leg_geometry.locations.size()});
return steps;