X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/86d90bc46005c00f2367ad759804f528adc4c6a5..e1a2d9e61e5905bef2ffaa36353681cd33660215:/tests/features/api/search.feature diff --git a/tests/features/api/search.feature b/tests/features/api/search.feature index 9b861a7b..08b2653c 100644 --- a/tests/features/api/search.feature +++ b/tests/features/api/search.feature @@ -9,35 +9,35 @@ Feature: Search queries | road | Thoresby Road | city | Broxtowe | state | England - | country | United Kingdom + | country | U.*K.* | country_code | gb Scenario: House number search for non-street address Given the request parameters | accept-language - | en - When sending json search query "4 Pomocnia, Poland" with address - Then address of result 0 is + | en + When sending json search query "4 Pomocnia, Pokrzywnica, Poland" with address + Then address of result 0 contains | type | value | house_number | 4 - | suburb | Pomocnia | county | gmina Pokrzywnica | state | Masovian Voivodeship | postcode | 06-121 | country | Poland | country_code | pl + Then address of result 0 does not contain road Scenario: House number interpolation even Given the request parameters | accept-language - | en + | en When sending json search query "140 rue Don Bosco, Saguenay" with address Then address of result 0 contains | type | value | house_number | 140 - | road | rue Don Bosco - | city | Saguenay + | road | [Rr]ue Don Bosco + | city | .*Saguenay | state | Quebec | country | Canada | country_code | ca @@ -45,30 +45,42 @@ Feature: Search queries Scenario: House number interpolation odd Given the request parameters | accept-language - | en + | en When sending json search query "141 rue Don Bosco, Saguenay" with address Then address of result 0 contains | type | value | house_number | 141 - | road | rue Don Bosco - | city | Saguenay + | road | [rR]ue Don Bosco + | city | .*Saguenay | state | Quebec | country | Canada | country_code | ca + @Tiger Scenario: TIGER house number When sending json search query "3 West Victory Way, Craig" - Then result 0 has not attributes osm_id,osm_type + Then results contain + | osm_type + | tiger + @Tiger Scenario: TIGER house number (road fallback) When sending json search query "3030 West Victory Way, Craig" - Then result 0 has attributes osm_id,osm_type + Then results contain + | osm_type + | way Scenario: Expansion of Illinois Given the request parameters | accept-language - | en + | en When sending json search query "il, us" Then results contain | ID | display_name | 0 | Illinois.* + + Scenario: Search with class-type feature + When sending jsonv2 search query "Hotel California" + Then results contain + | place_rank + | 30