summaryrefslogtreecommitdiff
path: root/webtest/http.py
diff options
context:
space:
mode:
authorGael Pasgrimaud <gael@gawel.org>2013-04-17 13:44:12 +0200
committerGael Pasgrimaud <gael@gawel.org>2013-04-17 13:44:12 +0200
commit008ea0cc69eac3c23a90ea3731d03777d6fb449a (patch)
tree8a4aee1ca8a8b12422675f71e189b5ad18b11e68 /webtest/http.py
parent670f9c8570f50d2697988c48271fff3060404b14 (diff)
downloadwebtest-008ea0cc69eac3c23a90ea3731d03777d6fb449a.tar.gz
allow to use a fixed StopableWSGIServer
Diffstat (limited to 'webtest/http.py')
-rw-r--r--webtest/http.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/webtest/http.py b/webtest/http.py
index 97d6563..86e47f9 100644
--- a/webtest/http.py
+++ b/webtest/http.py
@@ -108,7 +108,8 @@ class StopableWSGIServer(WSGIServer):
"""Start a server to serve ``application``. Return a server
instance."""
host, port = get_free_port()
- kwargs['port'] = port
+ if 'port' not in kwargs:
+ kwargs['port'] = port
if 'host' not in kwargs:
kwargs['host'] = host
if 'expose_tracebacks' not in kwargs: