Remove compass direction test handling
This commit is contained in:
committed by
Patrick Niklaus
parent
6244063073
commit
fd000cad86
@@ -128,12 +128,8 @@ module.exports = function () {
|
||||
return this.extractInstructionList(instructions, s => s.name);
|
||||
};
|
||||
|
||||
this.compassList = (instructions) => {
|
||||
return this.extractInstructionList(instructions, () => 'n'); // TODO fixme
|
||||
};
|
||||
|
||||
this.bearingList = (instructions) => {
|
||||
return this.extractInstructionList(instructions, s => s.bearing_after);
|
||||
return this.extractInstructionList(instructions, s => s.maneuver.bearing_after);
|
||||
};
|
||||
|
||||
this.turnList = (instructions) => {
|
||||
|
||||
@@ -31,7 +31,7 @@ module.exports = function () {
|
||||
var afterRequest = (err, res, body) => {
|
||||
if (err) return cb(err);
|
||||
if (body && body.length) {
|
||||
var instructions, bearings, compasses, turns, modes, times, distances;
|
||||
var instructions, bearings, turns, modes, times, distances;
|
||||
|
||||
var json = JSON.parse(body);
|
||||
|
||||
@@ -40,7 +40,6 @@ module.exports = function () {
|
||||
if (hasRoute) {
|
||||
instructions = this.wayList(json.routes[0]);
|
||||
bearings = this.bearingList(json.routes[0]);
|
||||
compasses = this.compassList(json.routes[0]);
|
||||
turns = this.turnList(json.routes[0]);
|
||||
modes = this.modeList(json.routes[0]);
|
||||
times = this.timeList(json.routes[0]);
|
||||
@@ -115,7 +114,6 @@ module.exports = function () {
|
||||
};
|
||||
|
||||
putValue('bearing', bearings);
|
||||
putValue('compass', compasses);
|
||||
putValue('turns', turns);
|
||||
putValue('modes', modes);
|
||||
putValue('times', times);
|
||||
|
||||
Reference in New Issue
Block a user