2016-07-19 04:30:11 -04:00
|
|
|
@routing @testbot @sidebias
|
|
|
|
Feature: Testbot - side bias
|
|
|
|
|
2017-05-18 08:27:28 -04:00
|
|
|
Scenario: Left-hand bias
|
|
|
|
Given the profile file "car" initialized with
|
2016-09-26 16:25:54 -04:00
|
|
|
"""
|
2017-05-18 08:27:28 -04:00
|
|
|
profile.left_hand_driving = true
|
|
|
|
profile.turn_bias = 1/1.075
|
2016-09-26 16:25:54 -04:00
|
|
|
"""
|
|
|
|
Given the node map
|
2016-09-30 03:33:08 -04:00
|
|
|
"""
|
|
|
|
a b c
|
|
|
|
|
|
|
|
d
|
|
|
|
"""
|
2016-07-19 04:30:11 -04:00
|
|
|
And the ways
|
|
|
|
| nodes |
|
|
|
|
| ab |
|
|
|
|
| bc |
|
|
|
|
| bd |
|
|
|
|
|
|
|
|
When I route I should get
|
|
|
|
| from | to | route | time |
|
2017-02-07 08:05:24 -05:00
|
|
|
| d | a | bd,ab,ab | 24s +-1 |
|
|
|
|
| d | c | bd,bc,bc | 27s +-1 |
|
2016-07-19 04:30:11 -04:00
|
|
|
|
2017-05-18 08:27:28 -04:00
|
|
|
Scenario: Right-hand bias
|
|
|
|
Given the profile file "car" initialized with
|
2016-09-26 16:25:54 -04:00
|
|
|
"""
|
2017-05-18 08:27:28 -04:00
|
|
|
profile.left_hand_driving = true
|
|
|
|
profile.turn_bias = 1.075
|
2016-09-26 16:25:54 -04:00
|
|
|
"""
|
2016-07-19 04:30:11 -04:00
|
|
|
And the node map
|
2016-09-30 03:33:08 -04:00
|
|
|
"""
|
|
|
|
a b c
|
|
|
|
|
|
|
|
d
|
|
|
|
"""
|
2016-07-19 04:30:11 -04:00
|
|
|
And the ways
|
|
|
|
| nodes |
|
|
|
|
| ab |
|
|
|
|
| bc |
|
|
|
|
| bd |
|
|
|
|
|
|
|
|
When I route I should get
|
|
|
|
| from | to | route | time |
|
2017-02-07 08:05:24 -05:00
|
|
|
| d | a | bd,ab,ab | 27s +-1 |
|
|
|
|
# should be inverse of left hand bias
|
|
|
|
| d | c | bd,bc,bc | 24s +-1 |
|