Account for imprecision in distance computation
This commit is contained in:
parent
24fa94af59
commit
f19bf70b55
@ -8,7 +8,7 @@ Feature: Bike - Surfaces
|
||||
Then routability should be
|
||||
| highway | surface | bothw |
|
||||
| cycleway | | 48 s |
|
||||
| cycleway | asphalt | 48 s |
|
||||
| cycleway | asphalt | 47.9 s|
|
||||
| cycleway | cobblestone:flattened | 72 s |
|
||||
| cycleway | paving_stones | 72 s |
|
||||
| cycleway | compacted | 72 s |
|
||||
@ -26,7 +26,7 @@ Feature: Bike - Surfaces
|
||||
Then routability should be
|
||||
| highway | surface | bothw |
|
||||
| cycleway | | 48 s |
|
||||
| path | | 59.9 s +- 1 |
|
||||
| path | | 59.9 s|
|
||||
| track | | 60 s |
|
||||
| track | asphalt | 60 s |
|
||||
| path | asphalt | 60 s |
|
||||
|
@ -37,7 +37,7 @@ module.exports = function () {
|
||||
outputRow[direction] = result[direction].status ?
|
||||
result[direction].status.toString() : '';
|
||||
break;
|
||||
case /^\d+ s/.test(want):
|
||||
case /^[\d\.]+ s/.test(want):
|
||||
// the result here can come back as a non-number value like
|
||||
// `diff`, but we only want to apply the unit when it comes
|
||||
// back as a number, for tableDiff's literal comparison
|
||||
|
Loading…
Reference in New Issue
Block a user