check weights consistency after updates

This commit is contained in:
Michael Krasnyk
2017-02-07 20:55:02 +01:00
committed by Patrick Niklaus
parent 005124fe1c
commit 28a8154cee
2 changed files with 60 additions and 7 deletions
+6 -6
View File
@@ -215,7 +215,7 @@ Feature: Weight tests
end
function turn_function (turn)
print (turn.angle)
turn.weight = turn.angle / 100
turn.weight = 2 + turn.angle / 100
turn.duration = turn.angle
end
"""
@@ -234,11 +234,11 @@ Feature: Weight tests
When I route I should get
| waypoints | route | distance | weights | times |
| a,c | , | 40m +-.1 | 3.119,0 | 289.9s,0s |
| a,e | ,, | 60m +-.1 | 3.119,1.11,0 | 289.9s,100s,0s |
| e,a | ,, | 60m +-.1 | 0.211,2.22,0 | 10.1s,200s,0s |
| e,d | ,, | 40m +-.1 | 2.009,1.11,0 | 189.9s,100s,0s |
| d,e | ,, | 40m +-.1 | 0.211,1.11,0 | 10.1s,100s,0s |
| a,c | , | 40m +-.1 | 5.119,0 | 289.9s,0s |
| a,e | ,, | 60m +-.1 | 5.119,1.11,0 | 289.9s,100s,0s |
| e,a | ,, | 60m +-.1 | 2.21,2.22,0 | 10.1s,200s,0s |
| e,d | ,, | 40m +-.1 | 4.009,1.11,0 | 189.9s,100s,0s |
| d,e | ,, | 40m +-.1 | 2.21,1.11,0 | 10.1s,100s,0s |
Scenario: Step weights -- segment_function with speed and turn updates
Given the profile file "testbot" extended with