Bearing is reported as integer only, fixes cucumber tests for issue #292
This commit is contained in:
+11
-11
@@ -13,7 +13,7 @@ Feature: Compass bearing
|
||||
|
||||
When I route I should get
|
||||
| from | to | route | compass | bearing |
|
||||
| a | b | ab | NW | 45 |
|
||||
| a | b | ab | NW | 315 |
|
||||
|
||||
@west
|
||||
Scenario: Bearing when going west
|
||||
@@ -26,7 +26,7 @@ Feature: Compass bearing
|
||||
|
||||
When I route I should get
|
||||
| from | to | route | compass | bearing |
|
||||
| a | b | ab | W | 90 |
|
||||
| a | b | ab | W | 270 |
|
||||
|
||||
Scenario: Bearing af 45 degree intervals
|
||||
Given the node map
|
||||
@@ -48,13 +48,13 @@ Feature: Compass bearing
|
||||
When I route I should get
|
||||
| from | to | route | compass | bearing |
|
||||
| x | a | xa | N | 0 |
|
||||
| x | b | xb | NW | 45 |
|
||||
| x | c | xc | W | 90 |
|
||||
| x | d | xd | SW | 135 |
|
||||
| x | b | xb | NW | 315 |
|
||||
| x | c | xc | W | 270 |
|
||||
| x | d | xd | SW | 225 |
|
||||
| x | e | xe | S | 180 |
|
||||
| x | f | xf | SE | 225 |
|
||||
| x | g | xg | E | 270 |
|
||||
| x | h | xh | NE | 315 |
|
||||
| x | f | xf | SE | 135 |
|
||||
| x | g | xg | E | 90 |
|
||||
| x | h | xh | NE | 45 |
|
||||
|
||||
Scenario: Bearing in a roundabout
|
||||
Given the node map
|
||||
@@ -76,8 +76,8 @@ Feature: Compass bearing
|
||||
|
||||
When I route I should get
|
||||
| from | to | route | compass | bearing |
|
||||
| c | b | cd,de,ef,fg,gh,ha,ab | W,SW,S,SE,E,NE,N | 90,135,180,225,270,0,45 |
|
||||
| g | f | gh,ha,ab,bc,cd,de,ef | E,NE,N,NW,W,SW,S | 270,315,0,45,90,180,225 |
|
||||
| c | b | cd,de,ef,fg,gh,ha,ab | W,SW,S,SE,E,NE,N | 270,225,180,135,90,45,0 |
|
||||
| g | f | gh,ha,ab,bc,cd,de,ef | E,NE,N,NW,W,SW,S | 90,45,0,315,270,225,180 |
|
||||
|
||||
Scenario: Bearing should stay constant when zig-zagging
|
||||
Given the node map
|
||||
@@ -96,4 +96,4 @@ Feature: Compass bearing
|
||||
|
||||
When I route I should get
|
||||
| from | to | route | compass | bearing |
|
||||
| a | h | ab,bc,cd,de,ef,fg,gh | N,SE,N,SE,N,SE,N | 0,225,0,225,0,225,0 |
|
||||
| a | h | ab,bc,cd,de,ef,fg,gh | N,SE,N,SE,N,SE,N | 0,135,0,135,0,135,0 |
|
||||
|
||||
Reference in New Issue
Block a user