2 Feature: Search queries
3 Generic search result correctness
5 Scenario: House number search for non-street address
6 When sending json search query "6 Silum, Liechtenstein" with address
9 Then address of result 0 is
13 | town | Triesenberg |
16 | country | Liechtenstein |
19 Scenario: House number interpolation
20 When sending json search query "Grosssteg 1023, Triesenberg" with address
23 Then address of result 0 contains
25 | house_number | 1023 |
29 | town | Triesenberg |
30 | country | Liechtenstein |
33 Scenario: With missing housenumber search falls back to road
34 When sending json search query "Bündaweg 555" with address
35 Then address of result 0 is
41 | town | Triesenberg |
42 | country | Liechtenstein |
45 Scenario Outline: Housenumber 0 can be found
46 When sending <format> search query "Gnalpstrasse 0" with address
50 And result addresses contain
62 Scenario: TIGER house number
63 When sending json search query "697 Upper Kingston Road"
65 | osm_type | display_name |
68 Scenario: Search with class-type feature
69 When sending jsonv2 search query "Hotel in California"
74 Scenario: Search with specific amenity
75 When sending json search query "[restaurant] Vaduz" with address
76 Then result addresses contain
81 | amenity | restaurant |
83 Scenario: Search with key-value amenity
84 When sending json search query "[club=scout] Vaduz"
89 Scenario: With multiple amenity search only the first is used
90 When sending json search query "[club=scout] [church] vaduz"
94 When sending json search query "[amenity=place_of_worship] [club=scout] vaduz"
97 | amenity | place_of_worship |
99 Scenario: POI search near given coordinate
100 When sending json search query "restaurant near 47.16712,9.51100"
103 | amenity | restaurant |
105 Scenario: Arbitrary key/value search near given coordinate
106 When sending json search query "[leisure=firepit] 47.150° N 9.5340493° E"
109 | leisure | firepit |
111 Scenario: Arbitrary key/value search near given coordinate and named place
112 When sending json search query "[leisure=firepit] ebenholz 47° 9′ 26″ N 9° 36′ 45″ E"
115 | leisure | firepit |
117 Scenario: Name search near given coordinate
118 When sending json search query "sporry" with address
119 Then result addresses contain
122 When sending json search query "sporry, 47.10791,9.52676" with address
123 Then result addresses contain
127 Scenario: Name search near given coordinate without result
128 When sending json search query "sporry, N 47 15 7 W 9 61 26"
129 Then exactly 0 results are returned
131 Scenario: Arbitrary key/value search near a road
132 When sending json search query "[amenity=drinking_water] Wissfläckaweg"
135 | amenity | drinking_water |
137 Scenario: Ignore other country codes in structured search with country
138 When sending json search query ""
141 Then exactly 0 results are returned
143 Scenario: Ignore country searches when query is restricted to countries
144 When sending json search query "de"
147 Then exactly 0 results are returned
149 # https://trac.openstreetmap.org/ticket/5094
150 Scenario: housenumbers are ordered by complete match first
151 When sending json search query "Austrasse 11, Vaduz" with address
152 Then result addresses contain
153 | ID | house_number |
157 Scenario Outline: Coordinate searches with white spaces
158 When sending json search query "<data>"
159 Then exactly 1 result is returned
166 | sporry weiher, N 47.10791° E 9.52676° |
167 | sporry weiher, N 47.10791° E 9.52676° |
168 | sporry weiher , N 47.10791° E 9.52676° |
169 | sporry weiher, N 47.10791° E 9.52676° |
170 | sporry weiher
\v, N 47.10791° E 9.52676° |
172 Scenario: Searches with white spaces
173 When sending json search query "52 Bodastr
\v,
\fTriesenberg"
176 | highway | residential |
180 Scenario: Addressdetails always return the place type
181 When sending json search query "Vaduz" with address
182 Then result addresses contain