Skip to content
Permalink
Browse files

Update control images

  • Loading branch information
elpaso committed Jan 4, 2019
1 parent d499940 commit 3c2392808d086f861782dfb4a8ab934ea13f92e2
Showing with 14 additions and 0 deletions.
  1. +4 −0 tests/src/python/test_qgsserver.py
  2. +4 −0 tests/src/python/test_qgsserver_accesscontrol.py
  3. +3 −0 tests/src/python/test_qgsserver_accesscontrol_wms_getlegendgraphic.py
  4. +3 −0 tests/src/python/test_qgsserver_wms_getlegendgraphic.py
  5. BIN tests/testdata/control_images/qgis_server/WMS_GetLegendGraphic_BBox/WMS_GetLegendGraphic_BBox.png
  6. BIN tests/testdata/control_images/qgis_server/WMS_GetLegendGraphic_BBox2/WMS_GetLegendGraphic_BBox2.png
  7. BIN ...ta/control_images/qgis_server/WMS_GetLegendGraphic_Background/WMS_GetLegendGraphic_Background.png
  8. BIN ...ol_images/qgis_server/WMS_GetLegendGraphic_Background_Hex/WMS_GetLegendGraphic_Background_Hex.png
  9. BIN tests/testdata/control_images/qgis_server/WMS_GetLegendGraphic_Basic/WMS_GetLegendGraphic_Basic.png
  10. BIN ...stdata/control_images/qgis_server/WMS_GetLegendGraphic_BoxSpace/WMS_GetLegendGraphic_BoxSpace.png
  11. BIN ...ol_images/qgis_server/WMS_GetLegendGraphic_IconLabelSpace/WMS_GetLegendGraphic_IconLabelSpace.png
  12. BIN ...stdata/control_images/qgis_server/WMS_GetLegendGraphic_ItemFont/WMS_GetLegendGraphic_ItemFont.png
  13. BIN ...data/control_images/qgis_server/WMS_GetLegendGraphic_LayerFont/WMS_GetLegendGraphic_LayerFont.png
  14. BIN ...ta/control_images/qgis_server/WMS_GetLegendGraphic_LayerSpace/WMS_GetLegendGraphic_LayerSpace.png
  15. BIN ...mages/qgis_server/WMS_GetLegendGraphic_ShowFeatureCount/WMS_GetLegendGraphic_ShowFeatureCount.png
  16. BIN ...ta/control_images/qgis_server/WMS_GetLegendGraphic_SymbolSize/WMS_GetLegendGraphic_SymbolSize.png
  17. BIN .../control_images/qgis_server/WMS_GetLegendGraphic_SymbolSpace/WMS_GetLegendGraphic_SymbolSpace.png
  18. BIN tests/testdata/control_images/qgis_server/WMS_GetLegendGraphic_rule0/WMS_GetLegendGraphic_rule0.png
  19. BIN tests/testdata/control_images/qgis_server/WMS_GetLegendGraphic_rule1/WMS_GetLegendGraphic_rule1.png
  20. BIN ..._images/qgis_server/WMS_GetLegendGraphic_rulelabel_false/WMS_GetLegendGraphic_rulelabel_false.png
  21. BIN tests/testdata/control_images/qgis_server/WMS_GetLegendGraphic_test/WMS_GetLegendGraphic_test.png
  22. BIN ..._server/WMS_GetLegendGraphic_test_layertitle_false/WMS_GetLegendGraphic_test_layertitle_false.png
  23. BIN ...ol_images/qgis_server_accesscontrol/WMS_GetLegendGraphic_Country/WMS_GetLegendGraphic_Country.png
  24. BIN ...ontrol_images/qgis_server_accesscontrol/WMS_GetLegendGraphic_Hello/WMS_GetLegendGraphic_Hello.png
  25. BIN tests/testdata/qgis_server_accesscontrol/geo.gpkg
@@ -185,6 +185,10 @@ def _img_diff(self, image, control_image, max_diff, max_size_diff=QSize()):
return control.compareImages(control_image, max_diff), control.report()

def _img_diff_error(self, response, headers, image, max_diff=100, max_size_diff=QSize()):

reference_path = unitTestDataPath('control_images') + '/qgis_server/' + image + '/' + image + '.png'
self.store_reference(reference_path, response)

self.assertEqual(
headers.get("Content-Type"), "image/png",
"Content type is wrong: %s\n%s" % (headers.get("Content-Type"), response))
@@ -217,6 +217,10 @@ def _img_diff(self, image, control_image, max_diff, max_size_diff=QSize()):
return control.compareImages(control_image), control.report()

def _img_diff_error(self, response, headers, image, max_diff=10, max_size_diff=QSize()):

reference_path = unitTestDataPath('control_images') + '/qgis_server_accesscontrol/' + image + '/' + image + '.png'
self.store_reference(reference_path, response)

self.assertEqual(
headers.get("Content-Type"), "image/png",
"Content type is wrong: %s" % headers.get("Content-Type"))
@@ -24,6 +24,9 @@

class TestQgsServerAccessControlWMSGetlegendgraphic(TestQgsServerAccessControl):

# Set to True to re-generate reference files for this class
#regenerate_reference = True

def test_wms_getlegendgraphic_hello(self):
query_string = "&".join(["%s=%s" % i for i in list({
"MAP": urllib.parse.quote(self.projectPath),
@@ -42,6 +42,9 @@
class TestQgsServerWMSGetLegendGraphic(QgsServerTestBase):
"""QGIS Server WMS Tests for GetLegendGraphic request"""

# Set to True to re-generate reference files for this class
#regenerate_reference = True

def test_getLegendGraphics(self):
"""Test that does not return an exception but an image"""
parms = {
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

0 comments on commit 3c23928

Please sign in to comment.
You can’t perform that action at this time.