Makes bicycle and foot profile's name and ref tag handling consistent with car profile
This commit is contained in:
parent
206bdff9e7
commit
f0069d3dcc
@ -10,13 +10,13 @@ Feature: Bike - Street names in instructions
|
||||
| | c |
|
||||
|
||||
And the ways
|
||||
| nodes | name |
|
||||
| ab | My Way |
|
||||
| bc | Your Way |
|
||||
| nodes | name | ref |
|
||||
| ab | My Way | A6 |
|
||||
| bc | Your Way | A7 |
|
||||
|
||||
When I route I should get
|
||||
| from | to | route |
|
||||
| a | c | My Way,Your Way,Your Way |
|
||||
| from | to | route |
|
||||
| a | c | My Way (A6),Your Way (A7),Your Way (A7) |
|
||||
|
||||
@unnamed
|
||||
Scenario: Bike - Use way type to describe unnamed ways
|
||||
|
@ -14,7 +14,7 @@ Feature: Bike - Way ref
|
||||
|
||||
When I route I should get
|
||||
| from | to | route |
|
||||
| a | b | Utopia Drive / E7,Utopia Drive / E7 |
|
||||
| a | b | Utopia Drive (E7),Utopia Drive (E7) |
|
||||
|
||||
Scenario: Bike - Way with only ref
|
||||
Given the node map
|
||||
|
@ -10,13 +10,13 @@ Feature: Foot - Street names in instructions
|
||||
| | c |
|
||||
|
||||
And the ways
|
||||
| nodes | name |
|
||||
| ab | My Way |
|
||||
| bc | Your Way |
|
||||
| nodes | name | ref |
|
||||
| ab | My Way | A6 |
|
||||
| bc | Your Way | B7 |
|
||||
|
||||
When I route I should get
|
||||
| from | to | route |
|
||||
| a | c | My Way,Your Way,Your Way |
|
||||
| from | to | route |
|
||||
| a | c | My Way (A6),Your Way (B7),Your Way (B7) |
|
||||
|
||||
@unnamed
|
||||
Scenario: Foot - Use way type to describe unnamed ways
|
||||
|
@ -14,7 +14,7 @@ Feature: Foot - Way ref
|
||||
|
||||
When I route I should get
|
||||
| from | to | route |
|
||||
| a | b | Utopia Drive / E7,Utopia Drive / E7 |
|
||||
| a | b | Utopia Drive (E7),Utopia Drive (E7) |
|
||||
|
||||
Scenario: Foot - Way with only ref
|
||||
Given the node map
|
||||
|
@ -210,7 +210,7 @@ function way_function (way, result)
|
||||
|
||||
-- name
|
||||
if ref and "" ~= ref and name and "" ~= name then
|
||||
result.name = name .. ' / ' .. ref
|
||||
result.name = name .. " (" .. ref .. ")"
|
||||
elseif ref and "" ~= ref then
|
||||
result.name = ref
|
||||
elseif name and "" ~= name then
|
||||
|
@ -151,7 +151,7 @@ function way_function (way, result)
|
||||
|
||||
-- name
|
||||
if ref and "" ~= ref and name and "" ~= name then
|
||||
result.name = name .. ' / ' .. ref
|
||||
result.name = name .. " (" .. ref .. ")"
|
||||
elseif ref and "" ~= ref then
|
||||
result.name = ref
|
||||
elseif name and "" ~= name then
|
||||
|
Loading…
Reference in New Issue
Block a user