From b84d70d305e238db30f6d086f6fe69501ab777dd Mon Sep 17 00:00:00 2001 From: Patrick Niklaus Date: Sun, 20 Nov 2016 15:20:57 +0000 Subject: [PATCH] Add regression test for nil values --- features/testbot/nil.feature | 42 ++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 features/testbot/nil.feature diff --git a/features/testbot/nil.feature b/features/testbot/nil.feature new file mode 100644 index 000000000..bb5372948 --- /dev/null +++ b/features/testbot/nil.feature @@ -0,0 +1,42 @@ +@routing @testbot @nil +Feature: Testbot - Check assigning nil values + Scenario: Assign nil values to all way strings + Given the profile file "testbot" extended with + """ + function way_function (way, result) + result.name = "name" + result.ref = "ref" + result.destinations = "destinations" + result.pronunciation = "pronunciation" + result.turn_lanes_forward = "turn_lanes_forward" + result.turn_lanes_backward = "turn_lanes_backward" + + result.name = nil + result.ref = nil + result.destinations = nil + result.pronunciation = nil + result.turn_lanes_forward = nil + result.turn_lanes_backward = nil + + result.forward_speed = 10 + result.backward_speed = 10 + result.forward_mode = mode.driving + result.backward_mode = mode.driving + end + """ + Given the node map + """ + a b c + + d + """ + And the ways + | nodes | + | ab | + | bc | + | bd | + + When I route I should get + | from | to | route | + | a | d | ,, | + | d | a | ,, |