]> git.openstreetmap.org Git - nominatim.git/blob - test/bdd/api/reverse/layers.feature
do not rename parameters in existing SQL function
[nominatim.git] / test / bdd / api / reverse / layers.feature
1 @SQLITE
2 @APIDB
3 Feature: Layer parameter in reverse geocoding
4     Testing correct function of layer selection while reverse geocoding
5
6     Scenario: POIs are selected by default
7         When sending v1/reverse at 47.14077,9.52414
8         Then results contain
9           | category | type      |
10           | tourism  | viewpoint |
11
12
13     Scenario Outline: Same address level POI with different layers
14         When sending v1/reverse at 47.14077,9.52414
15           | layer   |
16           | <layer> |
17         Then results contain
18           | category   |
19           | <category> |
20
21
22         Examples:
23           | layer           | category |
24           | address         | highway  |
25           | poi,address     | tourism  |
26           | address,poi     | tourism  |
27           | natural         | waterway |
28           | address,natural | highway  |
29           | natural,poi     | tourism  |
30
31
32      Scenario Outline: POIs are not selected without housenumber for address layer
33         When sending v1/reverse at 47.13816,9.52168
34           | layer   |
35           | <layer> |
36         Then results contain
37           | category   | type   |
38           | <category> | <type> |
39
40         Examples:
41           | layer       | category | type     |
42           | address,poi | highway  | bus_stop |
43           | address     | amenity  | parking  |
44
45
46      Scenario: Between natural and low-zoom address prefer natural
47          When sending v1/reverse at 47.13636,9.52094
48            | layer           | zoom |
49            | natural,address | 15   |
50          Then results contain
51            | category |
52            | waterway |
53
54
55     Scenario Outline: Search for mountain peaks begins at level 12
56         When sending v1/reverse at 47.08293,9.57109
57           | layer   | zoom   |
58           | natural | <zoom> |
59         Then results contain
60           | category   | type   |
61           | <category> | <type> |
62
63         Examples:
64           | zoom | category | type  |
65           | 12   | natural  | peak  |
66           | 13   | waterway | river |
67
68
69      Scenario Outline: Reverse search with manmade layers
70         When sending v1/reverse at 32.46904,-86.44439
71           | layer   |
72           | <layer> |
73         Then results contain
74           | category   | type   |
75           | <category> | <type> |
76
77         Examples:
78           | layer           | category | type        |
79           | manmade         | leisure  | park        |
80           | address         | highway  | residential |
81           | poi             | leisure  | pitch       |
82           | natural         | waterway | river       |
83           | natural,manmade | leisure  | park        |