Browse Source

Moving libpostal unit configuration into updated logic

pull/1052/head
semhul 7 years ago
parent
commit
66a458ffc7
  1. 1
      controller/libpostal.js
  2. 1
      package.json
  3. 5
      test/unit/controller/libpostal.js

1
controller/libpostal.js

@ -9,6 +9,7 @@ var field_mapping = {
island: 'island', island: 'island',
category: 'category', category: 'category',
house: 'query', house: 'query',
unit: 'unit',
house_number: 'number', house_number: 'number',
road: 'street', road: 'street',
suburb: 'neighbourhood', suburb: 'neighbourhood',

1
package.json

@ -62,7 +62,6 @@
"pelias-model": "sweco-semhul/model#adding-address-unit", "pelias-model": "sweco-semhul/model#adding-address-unit",
"pelias-query": "sweco-semhul/query#adding-address-unit", "pelias-query": "sweco-semhul/query#adding-address-unit",
"pelias-sorting": "1.1.0", "pelias-sorting": "1.1.0",
"pelias-text-analyzer": "sweco-semhul/text-analyzer#adding-address-unit",
"predicates": "^2.0.0", "predicates": "^2.0.0",
"retry": "^0.10.1", "retry": "^0.10.1",
"stats-lite": "^2.0.4", "stats-lite": "^2.0.4",

5
test/unit/controller/libpostal.js

@ -185,6 +185,10 @@ module.exports.tests.success_conditions = (test, common) => {
label: 'house', label: 'house',
value: 'house value' value: 'house value'
}, },
{
label: 'unit',
value: 'unit value'
},
{ {
label: 'house_number', label: 'house_number',
value: 'house_number value' value: 'house_number value'
@ -244,6 +248,7 @@ module.exports.tests.success_conditions = (test, common) => {
island: 'island value', island: 'island value',
category: 'category value', category: 'category value',
query: 'house value', query: 'house value',
unit: 'unit value',
number: 'house_number value', number: 'house_number value',
street: 'road value', street: 'road value',
neighbourhood: 'suburb value', neighbourhood: 'suburb value',

Loading…
Cancel
Save