Skip to content

Commit 3b45286

Browse files
committedJan 28, 2019
Add unit test for application/geo+json format
1 parent 80f3334 commit 3b45286

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed
 

‎tests/src/python/test_qgsserver_wms_getfeatureinfo.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -433,7 +433,7 @@ def testGetFeatureInfoTolerance(self):
433433
'test_project_values.qgz')
434434

435435
def testGetFeatureInfoJSON(self):
436-
# simple test without geometry
436+
# simple test without geometry and info_format=application/json
437437
self.wms_request_compare('GetFeatureInfo',
438438
'&layers=testlayer%20%C3%A8%C3%A9&styles=&' +
439439
'info_format=application%2Fjson&transparent=true&' +
@@ -442,6 +442,15 @@ def testGetFeatureInfoJSON(self):
442442
'query_layers=testlayer%20%C3%A8%C3%A9&X=190&Y=320',
443443
'wms_getfeatureinfo_json')
444444

445+
# simple test without geometry and info_format=application/geo+json
446+
self.wms_request_compare('GetFeatureInfo',
447+
'&layers=testlayer%20%C3%A8%C3%A9&styles=&' +
448+
'info_format=application%2Fgeo+json&transparent=true&' +
449+
'width=600&height=400&srs=EPSG%3A3857&bbox=913190.6389747962%2C' +
450+
'5606005.488876367%2C913235.426296057%2C5606035.347090538&' +
451+
'query_layers=testlayer%20%C3%A8%C3%A9&X=190&Y=320',
452+
'wms_getfeatureinfo_json')
453+
445454
# test with several features and several layers
446455
self.wms_request_compare('GetFeatureInfo',
447456
'&layers=testlayer%20%C3%A8%C3%A9,fields_alias,exclude_attribute&styles=&' +

0 commit comments

Comments
 (0)
Please sign in to comment.