From 445e5bed49eacc07eda926fcc7b9e6dff4125744 Mon Sep 17 00:00:00 2001 From: "Daniel J. Hofmann" Date: Wed, 27 Apr 2016 13:47:42 +0200 Subject: [PATCH] Respect ';'-separated list in destination:ref tag --- features/guidance/destination-signs.feature | 30 +++++++++++---------- profiles/lib/destination.lua | 2 +- 2 files changed, 17 insertions(+), 15 deletions(-) diff --git a/features/guidance/destination-signs.feature b/features/guidance/destination-signs.feature index a0eaac014..426fdb7f6 100644 --- a/features/guidance/destination-signs.feature +++ b/features/guidance/destination-signs.feature @@ -15,19 +15,21 @@ Feature: Destination Signs | m | n | And the ways - | nodes | name | ref | destination | destination:ref | - | ab | AB | E1 | | | - | cd | CD | | Berlin | | - | ef | EF | | Berlin | A1 | - | gh | | | Berlin | A1 | - | ij | | | Berlin | | - | kl | KL | E1 | Berlin | A1 | + | nodes | name | ref | destination | destination:ref | + | ab | AB | E1 | | | + | cd | CD | | Berlin | | + | ef | EF | | Berlin | A1 | + | gh | | | Berlin | A1 | + | ij | | | Berlin | | + | kl | KL | E1 | Berlin | A1 | + | mn | MN | | Berlin;Hamburg | A1;A2 | When I route I should get - | from | to | route | - | a | b | AB (E1),AB (E1) | - | c | d | CD (Berlin),CD (Berlin) | - | e | f | EF (A1: Berlin),EF (A1: Berlin) | - | g | h | , | - | i | j | , | - | k | l | KL (E1),KL (E1) | + | from | to | route | + | a | b | AB (E1),AB (E1) | + | c | d | CD (Berlin),CD (Berlin) | + | e | f | EF (A1: Berlin),EF (A1: Berlin) | + | g | h | , | + | i | j | , | + | k | l | KL (E1),KL (E1) | + | m | n | MN (A1, A2: Berlin, Hamburg),MN (A1, A2: Berlin, Hamburg) | diff --git a/profiles/lib/destination.lua b/profiles/lib/destination.lua index d89b1a926..fcdd677ea 100644 --- a/profiles/lib/destination.lua +++ b/profiles/lib/destination.lua @@ -10,7 +10,7 @@ function Destination.get_destination(way) local rv = "" if destination_ref and destination_ref ~= "" then - rv = rv .. destination_ref + rv = rv .. string.gsub(destination_ref, ";", ", ") end if destination and destination ~= "" then