Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove public_transport from features list #556

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion config/features.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const venue_tags = [
'building+name',
'shop+name',
'office+name',
'public_transport+name',
'highway:bus_stop+name',
'cuisine+name',
'railway~station+name',
'railway~tram_stop+name',
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@
"deep-diff": "^1.0.0",
"istanbul": "^0.4.3",
"jshint": "^2.10.3",
"json-diff": "^0.5.4",
"naivedb": "^1.0.7",
"pelias-mock-logger": "^1.0.1",
"precommit-hook": "^3.0.0",
Expand Down
2 changes: 1 addition & 1 deletion test/config/features.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ module.exports.tests.whitelist_venue_tags = function(test, common) {
t.true( features.venue_tags.includes('building+name') );
t.true( features.venue_tags.includes('shop+name') );
t.true( features.venue_tags.includes('office+name') );
t.true( features.venue_tags.includes('public_transport+name') );
t.true( features.venue_tags.includes('highway:bus_stop+name') );
t.true( features.venue_tags.includes('cuisine+name') );
t.true( features.venue_tags.includes('railway~tram_stop+name') );
t.true( features.venue_tags.includes('railway~station+name') );
Expand Down
12 changes: 4 additions & 8 deletions test/end-to-end.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ var fs = require('fs'),
path = require('path'),
colors = require('colors'),
deep = require('deep-diff'),
jdiff = require('json-diff'),
streams = require('../stream/importPipeline'),
model = require('pelias-model'),
sink = require('through2-sink'),
Expand Down Expand Up @@ -79,25 +80,20 @@ streams.pbfParser()
var d = deep.diff(actual[i], expected[i]);
if (d) {
countDiff++;
console.log(jdiff.diffString(actual[i], expected[i]));
}
else {
countSame++;
}
i++;
}
var diff = deep.diff( actual, expected );

if (!diff) {
if (countDiff === 0) {
fs.unlinkSync('actual_output.json');
fs.unlinkSync('expected_output.json');
}

if( diff ){
//added for clarification because understanding the deep diff output is hard
console.log('actual:', JSON.stringify(actual[0], null, 2));
console.log('expected:', JSON.stringify(expected[0], null, 2));

console.log( JSON.stringify(diff, null, 2) );
if (countDiff > 0){
console.log('actual count:', actual.length);
console.log('expected count:', expected.length);
console.log('matching count:', colors.green(countSame));
Expand Down
Loading