Don't fail on incorrect lane tags '1; 2'
This commit is contained in:
parent
1905a0f473
commit
86b70f2632
@ -35,3 +35,18 @@ Feature: Features related to bugs
|
||||
When I route I should get
|
||||
| waypoints | route | turns |
|
||||
| 1,2 | top,right,right | depart,new name right,arrive |
|
||||
|
||||
@3156
|
||||
Scenario: Incorrect lanes tag
|
||||
Given the node map
|
||||
"""
|
||||
a b
|
||||
"""
|
||||
|
||||
And the ways
|
||||
| nodes | lanes |
|
||||
| ab | 1; 2 |
|
||||
|
||||
And the data has been saved to disk
|
||||
When I try to run "osrm-extract {osm_file} --profile {profile_file}"
|
||||
Then it should exit successfully
|
||||
|
@ -63,7 +63,7 @@ function Guidance.set_classification (highway, result, input_way)
|
||||
local lane_count = input_way:get_value_by_key("lanes")
|
||||
if lane_count and lane_count ~= "" then
|
||||
local lc = tonumber(lane_count)
|
||||
if lane_count ~= nil then
|
||||
if lc ~= nil then
|
||||
result.road_classification.num_lanes = lc
|
||||
end
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user