Browse Source

getting all available parts of the local, regional array

output-generator-tweak
Harish Krishna 10 years ago
parent
commit
092ddc3fd0
  1. 1
      helper/outputGenerator.js
  2. 4
      test/unit/controller/doc.js
  3. 4
      test/unit/controller/search.js
  4. 4
      test/unit/controller/suggest.js
  5. 4
      test/unit/controller/suggest_nearby.js
  6. 6
      test/unit/helper/geojsonify.js

1
helper/outputGenerator.js

@ -16,7 +16,6 @@ module.exports = function( record ){
var rec = record[schemaArr[i]];
if (rec && rec.length) {
parts.push( rec );
return parts;
}
}
return parts;

4
test/unit/controller/doc.js

@ -30,7 +30,7 @@ module.exports.tests.functional_success = function(test, common) {
admin0: 'country1',
admin1: 'state1',
admin2: 'city1',
text: 'test name1, city1, state1'
text: 'test name1, city1, state1, country1'
}
}, {
type: 'Feature',
@ -46,7 +46,7 @@ module.exports.tests.functional_success = function(test, common) {
admin0: 'country2',
admin1: 'state2',
admin2: 'city2',
text: 'test name2, city2, state2'
text: 'test name2, city2, state2, country2'
}
}];

4
test/unit/controller/search.js

@ -31,7 +31,7 @@ module.exports.tests.functional_success = function(test, common) {
admin0: 'country1',
admin1: 'state1',
admin2: 'city1',
text: 'test name1, city1, state1'
text: 'test name1, city1, state1, country1'
}
}, {
type: 'Feature',
@ -47,7 +47,7 @@ module.exports.tests.functional_success = function(test, common) {
admin0: 'country2',
admin1: 'state2',
admin2: 'city2',
text: 'test name2, city2, state2'
text: 'test name2, city2, state2, country2'
}
}];

4
test/unit/controller/suggest.js

@ -31,7 +31,7 @@ module.exports.tests.functional_success = function(test, common) {
admin0: 'country1',
admin1: 'state1',
admin2: 'city1',
text: 'test name1, city1, state1'
text: 'test name1, city1, state1, country1'
}
}, {
type: 'Feature',
@ -47,7 +47,7 @@ module.exports.tests.functional_success = function(test, common) {
admin0: 'country2',
admin1: 'state2',
admin2: 'city2',
text: 'test name2, city2, state2'
text: 'test name2, city2, state2, country2'
}
}];

4
test/unit/controller/suggest_nearby.js

@ -31,7 +31,7 @@ module.exports.tests.functional_success = function(test, common) {
admin0: 'country1',
admin1: 'state1',
admin2: 'city1',
text: 'test name1, city1, state1'
text: 'test name1, city1, state1, country1'
}
}, {
type: 'Feature',
@ -47,7 +47,7 @@ module.exports.tests.functional_success = function(test, common) {
admin0: 'country2',
admin1: 'state2',
admin2: 'city2',
text: 'test name2, city2, state2'
text: 'test name2, city2, state2, country2'
}
}];

6
test/unit/helper/geojsonify.js

@ -116,7 +116,7 @@ module.exports.tests.search = function(test, common) {
'id': 'id1',
'type': 'type1',
'layer': 'type1',
'text': '\'Round Midnight Jazz and Blues Bar, test3, Angel',
'text': '\'Round Midnight Jazz and Blues Bar, test3, Angel, test1, test2, United Kingdom, Islington',
'name': '\'Round Midnight Jazz and Blues Bar',
'alpha3': 'GBR',
'admin0': 'United Kingdom',
@ -141,7 +141,7 @@ module.exports.tests.search = function(test, common) {
'id': 'id2',
'type': 'type2',
'layer': 'type2',
'text': 'Blues Cafe, test3, Smithfield',
'text': 'Blues Cafe, test3, Smithfield, test1, test2, United Kingdom, City And County Of The City Of London',
'name': 'Blues Cafe',
'alpha3': 'GBR',
'admin0': 'United Kingdom',
@ -166,7 +166,7 @@ module.exports.tests.search = function(test, common) {
'id': '34633854',
'type': 'osmway',
'layer': 'osmway',
'text': 'Empire State Building, Manhattan, NY',
'text': 'Empire State Building, Manhattan, New York, Koreatown, NY, United States',
'name': 'Empire State Building',
'alpha3': 'USA',
'admin0': 'United States',

Loading…
Cancel
Save