Add unit test for empty OGC filter

This commit is contained in:
Blottiere Paul 2018-09-03 08:36:41 +01:00
parent 2aeb5cf735
commit 34c1d7acce
2 changed files with 20 additions and 0 deletions

View File

@ -821,6 +821,26 @@ class TestQgsServerWMSGetMap(QgsServerTestBase):
r, h = self._result(self._execute_request(qs))
self._img_diff_error(r, h, "WMS_GetMap_Filter_OGC")
def test_wms_getmap_filter_ogc_empty(self):
filter = "(<ogc:Filter xmlns=\"http://www.opengis.net/ogc\"></ogc:Filter>)"
qs = "?" + "&".join(["%s=%s" % i for i in list({
"MAP": urllib.parse.quote(self.projectPath),
"SERVICE": "WMS",
"VERSION": "1.1.1",
"REQUEST": "GetMap",
"LAYERS": "Country,Hello",
"STYLES": "",
"FORMAT": "image/png",
"BBOX": "-16817707,-4710778,5696513,14587125",
"HEIGHT": "500",
"WIDTH": "500",
"CRS": "EPSG:3857",
"FILTER": filter
}.items())])
r, h = self._result(self._execute_request(qs))
self._img_diff_error(r, h, "WMS_GetMap_Filter_OGC2")
def test_wms_getmap_selection(self):
qs = "?" + "&".join(["%s=%s" % i for i in list({
"MAP": urllib.parse.quote(self.projectPath),

Binary file not shown.

After

Width:  |  Height:  |  Size: 52 KiB