Skip to content
Permalink
Browse files

[server][test] Add protocol and host:port to path in the test server

  • Loading branch information
elpaso committed Jan 17, 2018
1 parent 8c74c5b commit 4fc2b3e808136ec6b01ac47a8705864e82939659
Showing with 2 additions and 0 deletions.
  1. +2 −0 tests/src/python/qgis_wrapped_server.py
@@ -166,6 +166,8 @@ def do_GET(self, post_body=None):
headers = {}
for k, v in self.headers.items():
headers['HTTP_%s' % k.replace(' ', '-').replace('-', '_').replace(' ', '-').upper()] = v
if not self.path.startswith('http'):
self.path = "%s://%s:%s%s" % ('https' if https else 'http', QGIS_SERVER_HOST, QGIS_SERVER_PORT, self.path)
request = QgsBufferServerRequest(self.path, (QgsServerRequest.PostMethod if post_body is not None else QgsServerRequest.GetMethod), headers, post_body)
response = QgsBufferServerResponse()
qgs_server.handleRequest(request, response)

0 comments on commit 4fc2b3e

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