2 Feature: Import and search of names
3 Tests all naming related issues: normalisation,
4 abbreviations, internationalisation, etc.
6 Scenario: Case-insensitivity of search
8 | osm | class | type | name |
9 | N1 | place | locality | FooBar |
12 | object | class | type | name+name |
13 | N1 | place | locality | FooBar |
14 When searching for "FooBar"
16 | ID | osm_type | osm_id |
18 When searching for "foobar"
20 | ID | osm_type | osm_id |
22 When searching for "fOObar"
24 | ID | osm_type | osm_id |
26 When searching for "FOOBAR"
28 | ID | osm_type | osm_id |
31 Scenario: Multiple spaces in name
33 | osm | class | type | name |
34 | N1 | place | locality | one two three |
36 When searching for "one two three"
38 | ID | osm_type | osm_id |
40 When searching for "one two three"
42 | ID | osm_type | osm_id |
44 When searching for "one two three"
46 | ID | osm_type | osm_id |
48 When searching for " one two three"
50 | ID | osm_type | osm_id |
53 Scenario: Special characters in name
55 | osm | class | type | name |
56 | N1 | place | locality | Jim-Knopf-Str |
57 | N2 | place | locality | Smith/Weston |
58 | N3 | place | locality | space mountain |
59 | N4 | place | locality | space |
60 | N5 | place | locality | mountain |
62 When searching for "Jim-Knopf-Str"
64 | ID | osm_type | osm_id |
66 When searching for "Jim Knopf-Str"
68 | ID | osm_type | osm_id |
70 When searching for "Jim Knopf Str"
72 | ID | osm_type | osm_id |
74 When searching for "Jim/Knopf-Str"
76 | ID | osm_type | osm_id |
78 When searching for "Jim-Knopfstr"
80 | ID | osm_type | osm_id |
82 When searching for "Smith/Weston"
84 | ID | osm_type | osm_id |
86 When searching for "Smith Weston"
88 | ID | osm_type | osm_id |
90 When searching for "Smith-Weston"
92 | ID | osm_type | osm_id |
94 When searching for "space mountain"
96 | ID | osm_type | osm_id |
98 When searching for "space-mountain"
100 | ID | osm_type | osm_id |
102 When searching for "space/mountain"
104 | ID | osm_type | osm_id |
106 When searching for "space\mountain"
108 | ID | osm_type | osm_id |
110 When searching for "space(mountain)"
112 | ID | osm_type | osm_id |
115 Scenario: Landuse with name are found
117 | osm | class | type | name | geometry |
118 | R1 | natural | meadow | landuse1 | (0 0, 1 0, 1 1, 0 1, 0 0) |
119 | R2 | landuse | industrial | landuse2 | (0 0, -1 0, -1 -1, 0 -1, 0 0) |
121 When searching for "landuse1"
123 | ID | osm_type | osm_id |
125 When searching for "landuse2"
127 | ID | osm_type | osm_id |
130 Scenario: Postcode boundaries without ref
132 | osm | class | type | postcode | geometry |
133 | R1 | boundary | postal_code | 12345 | (0 0, 1 0, 1 1, 0 1, 0 0) |
135 When searching for "12345"
137 | ID | osm_type | osm_id |
140 Scenario: Unprintable characters in postcodes are ignored
141 Given the named places
142 | osm | class | type | address |
143 | N234 | amenity | prison | 'postcode' : u'1234\u200e' |
145 And searching for "1234"
150 Scenario Outline: Housenumbers with special characters are found
155 | osm | class | type | name | geometry |
156 | W1 | highway | primary | Main St | 1,2 |
158 | osm | class | type | housenr | geometry |
159 | N1 | building | yes | <nr> | 9 |
161 And searching for "Main St <nr>"
163 | osm_type | osm_id | name |
164 | N | 1 | <nr>, Main St |