1 Feature: Import of simple objects by osm2pgsql
2 Testing basic tagging in osm2pgsql imports.
4 Scenario: Import simple objects
7 n1 Tamenity=prison,name=foo x34.3 y-23
15 w1 Tshop=toys,name=tata Nn100,n101,n102
16 w2 Tref=45 Nn200,n201,n202,n203,n200
17 r1 Ttype=multipolygon,tourism=hotel,name=XZ Mn1@,w2@
19 Then place contains exactly
20 | object | class | type | name!dict | geometry!wkt |
21 | N1 | amenity | prison | 'name' : 'foo' | 34.3 -23 |
22 | W1 | shop | toys | 'name' : 'tata' | 0 0, 0 0.1, 0.1 0.2 |
23 | R1 | tourism | hotel | 'name' : 'XZ' | (0 0, 0 1, 1 1, 1 0, 0 0) |
25 Scenario: Import object with two main tags
28 n1 Ttourism=hotel,amenity=restaurant,name=foo
30 Then place contains exactly
31 | object | class | type | name!dict | categories!set |
32 | N1 | amenity | restaurant | 'name' : 'foo' | 'osm.tourism.hotel', 'osm.amenity.restaurant' |
34 Scenario: Import stand-alone house number with postcode
37 n1 Taddr:housenumber=4,addr:postcode=3345
39 Then place contains exactly
40 | object | class | type |
41 | N1 | place | house |
43 Scenario Outline: Tags used by Nominatim internally are always imported
44 Given the lua style file
46 local flex = require('import-<style>')
50 n1 Tboundary=administrative,place=city,name=Foo,wikipedia:de=Foo
51 n2 Tplace=hamlet,wikidata=Q1234321,name=Bar
53 Then place contains exactly
54 | object | class | extratags!dict | categories!set |
55 | N1 | boundary | 'wikipedia:de': 'Foo' | 'osm.boundary.administrative', 'osm.place.city' |
56 | N2 | place | 'wikidata': 'Q1234321' | 'osm.place.hamlet' |