2 Feature: Update of relations by osm2pgsql
3 Testing relation update by osm2pgsql.
5 Scenario: Remove all members of a relation
8 n1 Tamenity=prison,name=foo
13 w2 Tref=45' Nn200,n201,n202,n203,n200
14 r1 Ttype=multipolygon,tourism=hotel,name=XZ Mw2@
17 | object | class | type | name |
18 | R1 | tourism | hotel | 'name' : 'XZ' |
19 When updating osm data
21 r1 Ttype=multipolygon,tourism=hotel,name=XZ Mn1@
23 Then place has no entry for R1
26 Scenario: Change type of a relation
33 w2 Tref=45 Nn200,n201,n202,n203,n200
34 r1 Ttype=multipolygon,tourism=hotel,name=XZ Mw2@
37 | object | class | type | name |
38 | R1 | tourism | hotel | 'name' : 'XZ' |
39 When updating osm data
41 r1 Ttype=multipolygon,amenity=prison,name=XZ Mw2@
43 Then place has no entry for R1:tourism
45 | object | class | type | name |
46 | R1 | amenity | prison | 'name' : 'XZ' |
48 Scenario: Change name of a relation
55 w2 Tref=45 Nn200,n201,n202,n203,n200
56 r1 Ttype=multipolygon,tourism=hotel,name=AB Mw2@
59 | object | class | type | name |
60 | R1 | tourism | hotel | 'name' : 'AB' |
61 When updating osm data
63 r1 Ttype=multipolygon,tourism=hotel,name=XY Mw2@
66 | object | class | type | name |
67 | R1 | tourism | hotel | 'name' : 'XY' |
69 Scenario: Change type of a relation into something unknown
76 w2 Tref=45 Nn200,n201,n202,n203,n200
77 r1 Ttype=multipolygon,tourism=hotel,name=XY Mw2@
80 | object | class | type | name |
81 | R1 | tourism | hotel | 'name' : 'XY' |
82 When updating osm data
84 r1 Ttype=multipolygon,amenities=prison,name=XY Mw2@
86 Then place has no entry for R1
88 Scenario: Type tag is removed
95 w2 Tref=45 Nn200,n201,n202,n203,n200
96 r1 Ttype=multipolygon,tourism=hotel,name=XY Mw2@
99 | object | class | type | name |
100 | R1 | tourism | hotel | 'name' : 'XY' |
101 When updating osm data
103 r1 Ttourism=hotel,name=XY Mw2@
105 Then place has no entry for R1
107 Scenario: Type tag is renamed to something unknown
108 When loading osm data
114 w2 Tref=45 Nn200,n201,n202,n203,n200
115 r1 Ttype=multipolygon,tourism=hotel,name=XY Mw2@
118 | object | class | type | name |
119 | R1 | tourism | hotel | 'name' : 'XY' |
120 When updating osm data
122 r1 Ttype=multipolygonn,tourism=hotel,name=XY Mw2@
124 Then place has no entry for R1
126 Scenario: Country boundary names are left untouched when country_code unknown
127 When loading osm data
129 n200 Tamenity=prison x0 y0
134 And updating osm data
136 w1 Nn200,n201,n202,n203,n200
137 r1 Ttype=boundary,boundary=administrative,name=Foo,country_code=XX,admin_level=2 Mw1@
140 | object | addr+country | name |
141 | R1 | XX | 'name' : 'Foo' |
143 Scenario: Country boundary names are extended when country_code known
144 When loading osm data
146 n200 Tamenity=prison x0 y0
151 And updating osm data
153 w1 Nn200,n201,n202,n203,n200
154 r1 Ttype=boundary,boundary=administrative,name=Foo,country_code=ch,admin_level=2 Mw1@
157 | object | addr+country | name+name:de | name+name |
158 | R1 | ch | Schweiz | Foo |