]> git.openstreetmap.org Git - nominatim.git/blob - test/bdd/api/reverse/params.feature
Merge pull request #802 from mtmail/coordinate-extract-missing-first-minus-sign
[nominatim.git] / test / bdd / api / reverse / params.feature
1 @APIDB
2 Feature: Parameters for Reverse API
3     Testing different parameter options for reverse API.
4
5     Scenario Outline: Reverse-geocoding without address
6         When sending <format> reverse coordinates 53.603,10.041
7           | addressdetails |
8           | 0 |
9         Then exactly 1 result is returned
10         And result has not attributes address
11
12     Examples:
13       | format |
14       | json |
15       | jsonv2 |
16       | xml |
17
18     Scenario Outline: Coordinates must be floating-point numbers
19         When sending reverse coordinates <coords>
20         Then a HTTP 400 is returned
21
22     Examples:
23       | coords    |
24       | -45.3,;   |
25       | gkjd,50   |
26
27     Scenario Outline: Reverse Geocoding with extratags
28         When sending <format> reverse coordinates 10.776234290950017,106.70425325632095
29           | extratags |
30           | 1 |
31         Then result 0 has attributes extratags
32
33     Examples:
34         | format |
35         | xml |
36         | json |
37         | jsonv2 |
38
39     Scenario Outline: Reverse Geocoding with namedetails
40         When sending <format> reverse coordinates 10.776455623137625,106.70175343751907
41           | namedetails |
42           | 1 |
43         Then result 0 has attributes namedetails
44
45     Examples:
46         | format |
47         | xml |
48         | json |
49         | jsonv2 |
50
51     Scenario Outline: Reverse Geocoding contains TEXT geometry
52         When sending <format> reverse coordinates 47.165989816710066,9.515774846076965
53           | polygon_text |
54           | 1 |
55         Then result 0 has attributes <response_attribute>
56
57     Examples:
58         | format   | response_attribute |
59         | xml      | geotext |
60         | json     | geotext |
61         | jsonv2   | geotext |
62
63     Scenario Outline: Reverse Geocoding contains polygon-as-points geometry
64         When sending <format> reverse coordinates 47.165989816710066,9.515774846076965
65           | polygon |
66           | 1 |
67         Then result 0 has not attributes <response_attribute>
68
69     Examples:
70         | format   | response_attribute |
71         | xml      | polygonpoints |
72         | json     | polygonpoints |
73         | jsonv2   | polygonpoints |
74
75     Scenario Outline: Reverse Geocoding contains SVG geometry
76         When sending <format> reverse coordinates 47.165989816710066,9.515774846076965
77           | polygon_svg |
78           | 1 |
79         Then result 0 has attributes <response_attribute>
80
81     Examples:
82         | format   | response_attribute |
83         | xml      | geosvg |
84         | json     | svg |
85         | jsonv2   | svg |
86
87     Scenario Outline: Reverse Geocoding contains KML geometry
88         When sending <format> reverse coordinates 47.165989816710066,9.515774846076965
89           | polygon_kml |
90           | 1 |
91         Then result 0 has attributes <response_attribute>
92
93     Examples:
94         | format   | response_attribute |
95         | xml      | geokml |
96         | json     | geokml |
97         | jsonv2   | geokml |
98
99     Scenario Outline: Reverse Geocoding contains GEOJSON geometry
100         When sending <format> reverse coordinates 47.165989816710066,9.515774846076965
101           | polygon_geojson |
102           | 1 |
103         Then result 0 has attributes <response_attribute>
104
105     Examples:
106         | format   | response_attribute |
107         | xml      | geojson |
108         | json     | geojson |
109         | jsonv2   | geojson |
110
111