Skip to content

Commit 50d378f

Browse files
committed
Update tests for WMS grouped layers order
1 parent d7ef689 commit 50d378f

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

tests/src/python/test_qgsserver_wms_getmap.py

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -890,12 +890,15 @@ def test_wms_getmap_sld(self):
890890
self._img_diff_error(r, h, "WMS_GetMap_SLDRestored")
891891

892892
def test_wms_getmap_group(self):
893+
"""A WMS shall render the requested layers by drawing the leftmost in the list
894+
bottommost, the next one over that, and so on."""
895+
893896
qs = "?" + "&".join(["%s=%s" % i for i in list({
894897
"MAP": urllib.parse.quote(self.projectGroupsPath),
895898
"SERVICE": "WMS",
896899
"VERSION": "1.1.1",
897900
"REQUEST": "GetMap",
898-
"LAYERS": "Country,Country_Labels,Country_Diagrams",
901+
"LAYERS": "Country_Diagrams,Country_Labels,Country",
899902
"STYLES": "",
900903
"FORMAT": "image/png",
901904
"BBOX": "-16817707,-4710778,5696513,14587125",
@@ -921,6 +924,16 @@ def test_wms_getmap_group(self):
921924
}.items())])
922925

923926
r_group, _ = self._result(self._execute_request(qs))
927+
928+
""" Debug check:
929+
f = open('grouped.png', 'wb+')
930+
f.write(r_group)
931+
f.close()
932+
f = open('individual.png', 'wb+')
933+
f.write(r_individual)
934+
f.close()
935+
#"""
936+
924937
self.assertEqual(r_individual, r_group, 'Individual layers query and group layers query results should be identical')
925938

926939
qs = "?" + "&".join(["%s=%s" % i for i in list({

0 commit comments

Comments
 (0)