Skip to content

Commit

Permalink
Merge pull request #531 from pelias/nyc-labels
Browse files Browse the repository at this point in the history
Update tests for NYC Labels
  • Loading branch information
orangejulius authored Sep 14, 2020
2 parents 222c439 + 8364b31 commit 66cb00b
Show file tree
Hide file tree
Showing 9 changed files with 56 additions and 14 deletions.
2 changes: 1 addition & 1 deletion test_cases/address_matching.json
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@
"expected": {
"priorityThresh": 2,
"properties": [
{ "label": "190 Dean Street, Brooklyn, New York, NY, USA" }
{ "label": "190 Dean Street, Brooklyn, NY, USA" }
]
}
},
Expand Down
8 changes: 4 additions & 4 deletions test_cases/address_parsing.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"postalcode": "10009",
"housenumber": "101",
"street": "Saint Marks Place",
"label": "101 Saint Marks Place, Manhattan, New York, NY, USA"
"label": "101 Saint Marks Place, New York, NY, USA"
}
]
}
Expand Down Expand Up @@ -102,7 +102,7 @@
"postalcode": "11232",
"housenumber": "450",
"street": "37th Street",
"label": "450 37th Street, Brooklyn, New York, NY, USA"
"label": "450 37th Street, Brooklyn, NY, USA"
}
]
}
Expand Down Expand Up @@ -178,7 +178,7 @@
"postalcode": "11232",
"housenumber": "455",
"street": "43rd Street",
"label": "455 43rd Street, Brooklyn, New York, NY, USA"
"label": "455 43rd Street, Brooklyn, NY, USA"
}
]
}
Expand Down Expand Up @@ -206,7 +206,7 @@
"postalcode": "11201",
"housenumber": "1",
"street": "Main Street",
"label": "1 Main Street, Brooklyn, New York, NY, USA"
"label": "1 Main Street, Brooklyn, NY, USA"
}
]
}
Expand Down
2 changes: 1 addition & 1 deletion test_cases/admin_lookup.json
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@
"expected": {
"properties": [
{
"label": "Crown Heights, Brooklyn, New York, NY, USA",
"label": "Crown Heights, Brooklyn, NY, USA",
"name": "Crown Heights",
"country_a": "USA",
"country": "United States",
Expand Down
4 changes: 2 additions & 2 deletions test_cases/autocomplete_focus.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"expected": {
"properties": [
{
"label": "DiDi Dumpling, Manhattan, New York, NY, USA"
"label": "DiDi Dumpling, New York, NY, USA"
}
]
}
Expand Down Expand Up @@ -96,7 +96,7 @@
"priorityThresh": 1,
"properties": [
{
"label": "Hard Rock Cafe, Manhattan, New York, NY, USA"
"label": "Hard Rock Cafe, New York, NY, USA"
}
]
}
Expand Down
2 changes: 1 addition & 1 deletion test_cases/autocomplete_streets.json
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@
"expected": {
"priorityThresh": 2,
"properties": [
{ "label": "190 Dean Street, Brooklyn, New York, NY, USA" }
{ "label": "190 Dean Street, Brooklyn, NY, USA" }
]
}
}
Expand Down
5 changes: 4 additions & 1 deletion test_cases/autocomplete_venues.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,10 @@
"expected": {
"properties": [
{
"label": "DiDi Dumpling, Manhattan, New York, NY, USA"
"name": "DiDi Dumpling",
"borough": "Manhattan",
"region_a": "NY",
"country_a": "USA"
}
]
}
Expand Down
36 changes: 35 additions & 1 deletion test_cases/labels.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
},
"expected": {
"properties": [{
"label": "30 West 26th Street, Manhattan, New York, NY, USA"
"label": "30 West 26th Street, New York, NY, USA"
}]
}
},
Expand Down Expand Up @@ -392,6 +392,40 @@
}
]
}
},
{
"id": 25,
"status": "pass",
"description": "Queens address should use neighbourhood name in label",
"issue": "https://github.com/pelias/labels/pull/39",
"user": "julian",
"in": {
"text": "38-04 Broadway, Astoria, NY 11103"
},
"expected": {
"properties": [
{
"label": "38-04 Broadway, Astoria, NY, USA"
}
]
}
},
{
"id": 26,
"status": "pass",
"description": "Manhattan neighbourhood",
"issue": "https://github.com/pelias/labels/pull/39",
"user": "julian",
"in": {
"text": "East Village, nyc"
},
"expected": {
"properties": [
{
"label": "East Village, Manhattan, New York, NY, USA"
}
]
}
}
]
}
4 changes: 2 additions & 2 deletions test_cases/search.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"expected": {
"properties": [
{
"label": "Brooklyn, New York, NY, USA"
"label": "Brooklyn, NY, USA"
}
]
}
Expand All @@ -29,7 +29,7 @@
"expected": {
"properties": [
{
"label": "Brooklyn, New York, NY, USA"
"label": "Brooklyn, NY, USA"
}
]
}
Expand Down
7 changes: 6 additions & 1 deletion test_cases/search_coarse.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,12 @@
"expected": {
"properties": [
{
"label": "Brooklyn, New York, NY, USA"
"name": "Brooklyn",
"layer": "borough",
"locality": "New York",
"region_a": "NY",
"country_a": "USA",
"label": "Brooklyn, NY, USA"
}
]
}
Expand Down

0 comments on commit 66cb00b

Please sign in to comment.