Skip to content
Permalink
Browse files

Add unit tests

  • Loading branch information
pblottiere authored and rldhont committed May 2, 2018
1 parent 1636e6a commit 4962953a7b1b1059eee24afdf1cc074dc14da9c3
@@ -306,6 +306,23 @@ def test_project_wms_inspire(self):
for request in ('GetCapabilities',):
self.wms_inspire_request_compare(request)

def test_wms_getcapabilities_without_title(self):
# Empty title in project leads to a Layer element without Name, Title
# and Abstract tags. However, it should still have a CRS and a BBOX
# according to OGC specifications tests.
project = os.path.join(self.testdata_path, "test_project_without_title.qgs")
qs = "?" + "&".join(["%s=%s" % i for i in list({
"MAP": urllib.parse.quote(project),
"SERVICE": "WMS",
"VERSION": "1.3.0",
"REQUEST": "GetCapabilities",
"STYLES": ""
}.items())])

r, h = self._result(self._execute_request(qs))

self.wms_request_compare('GetCapabilities', reference_file='wms_getcapabilities_without_title', project='test_project_without_title.qgs')

def test_wms_getcapabilities_url(self):
# empty url in project
project = os.path.join(self.testdata_path, "test_project_without_urls.qgs")

3 comments on commit 4962953

@m-kuhn

This comment has been minimized.

Copy link
Member

@m-kuhn m-kuhn replied May 3, 2018

Looks like this unit test is failing: https://travis-ci.org/qgis/QGIS/jobs/374124060#L1537

@pblottiere

This comment has been minimized.

Copy link
Member Author

@pblottiere pblottiere replied May 3, 2018

Yes, due to an early backport. The PR #6926 fixes the issue.

@m-kuhn

This comment has been minimized.

Copy link
Member

@m-kuhn m-kuhn replied May 3, 2018

Ah, ok. I was just wondering why my backport was failing repeatedly. I'll wait for this one.

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