2 Feature: Import and search of names
3 Tests all naming related issues: normalisation,
4 abbreviations, internationalisation, etc.
6 Scenario: non-latin scripts can be found
8 | osm | class | type | name |
9 | N1 | place | locality | Речицкий район |
10 | N2 | place | locality | Refugio de montaña |
11 | N3 | place | locality | 高槻市|
12 | N4 | place | locality | الدوحة |
14 When sending search query "Речицкий район"
18 When sending search query "Refugio de montaña"
22 When sending search query "高槻市"
26 When sending search query "الدوحة"
31 Scenario: Case-insensitivity of search
33 | osm | class | type | name |
34 | N1 | place | locality | FooBar |
37 | object | class | type | name+name |
38 | N1 | place | locality | FooBar |
39 When sending search query "FooBar"
43 When sending search query "foobar"
47 When sending search query "fOObar"
51 When sending search query "FOOBAR"
56 Scenario: Multiple spaces in name
58 | osm | class | type | name |
59 | N1 | place | locality | one two three |
61 When sending search query "one two three"
65 When sending search query "one two three"
69 When sending search query "one two three"
73 When sending search query " one two three"
78 Scenario: Special characters in name
80 | osm | class | type | name+name:de |
81 | N1 | place | locality | Jim-Knopf-Straße |
82 | N2 | place | locality | Smith/Weston |
83 | N3 | place | locality | space mountain |
84 | N4 | place | locality | space |
85 | N5 | place | locality | mountain |
87 When sending search query "Jim-Knopf-Str"
91 When sending search query "Jim Knopf-Str"
95 When sending search query "Jim Knopf Str"
99 When sending search query "Jim/Knopf-Str"
103 When sending search query "Jim-Knopfstr"
107 When sending search query "Smith/Weston"
111 When sending search query "Smith Weston"
115 When sending search query "Smith-Weston"
119 When sending search query "space mountain"
123 When sending search query "space-mountain"
127 When sending search query "space/mountain"
131 When sending search query "space\mountain"
135 When sending search query "space(mountain)"
140 Scenario: Landuse with name are found
142 | osm | class | type | name | geometry |
143 | R1 | natural | meadow | landuse1 | (0 0, 1 0, 1 1, 0 1, 0 0) |
144 | R2 | landuse | industrial | landuse2 | (0 0, -1 0, -1 -1, 0 -1, 0 0) |
146 When sending search query "landuse1"
150 When sending search query "landuse2"
155 Scenario: Postcode boundaries without ref
157 | osm | class | type | postcode | geometry |
158 | R1 | boundary | postal_code | 12345 | (0 0, 1 0, 1 1, 0 1, 0 0) |
160 When sending search query "12345"
165 Scenario: Unprintable characters in postcodes are ignored
166 Given the named places
167 | osm | class | type | address | geometry |
168 | N234 | amenity | prison | 'postcode' : u'1234\u200e' | country:de |
170 And sending search query "1234"
171 Then result 0 has not attributes osm_type
173 Scenario Outline: Housenumbers with special characters are found
178 | osm | class | type | name | geometry |
179 | W1 | highway | primary | Main St | 1,2 |
181 | osm | class | type | housenr | geometry |
182 | N1 | building | yes | <nr> | 9 |
184 And sending search query "Main St <nr>"
186 | osm | display_name |
187 | N1 | <nr>, Main St |
201 Scenario Outline: Housenumbers in lists are found
206 | osm | class | type | name | geometry |
207 | W1 | highway | primary | Main St | 1,2 |
209 | osm | class | type | housenr | geometry |
210 | N1 | building | yes | <nr-list> | 9 |
212 And sending search query "Main St <nr>"
214 | osm | display_name |
215 | N1 | <nr-list>, Main St |