summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiro HronĨok <miro@hroncok.cz>2019-07-10 15:21:35 +0200
committerJakub Stasiak <jakub@stasiak.at>2019-07-10 16:03:47 +0200
commit7f8d478686532c314ad013840aa6388ec190f736 (patch)
treebdfcc892b966a2ca5780f3436e8defefd1c3290d
parent5b04426586d88aaf23dcb9cd86cd7bf53c974c1e (diff)
downloadeventlet-7f8d478686532c314ad013840aa6388ec190f736.tar.gz
Stop using deprecated cgi.parse_qs() to support Python 3.8
Fixes https://github.com/eventlet/eventlet/issues/580
-rw-r--r--tests/wsgi_test.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/wsgi_test.py b/tests/wsgi_test.py
index 9405d80..cd87863 100644
--- a/tests/wsgi_test.py
+++ b/tests/wsgi_test.py
@@ -22,6 +22,7 @@ from eventlet.green import socket as greensocket
from eventlet.green import ssl
from eventlet.support import bytes_to_str
import six
+from six.moves.urllib import parse
import tests
@@ -318,7 +319,7 @@ class TestHttpd(_TestBase):
# define a new handler that does a get_arg as well as a read_body
def new_app(env, start_response):
body = bytes_to_str(env['wsgi.input'].read())
- a = cgi.parse_qs(body).get('a', [1])[0]
+ a = parse.parse_qs(body).get('a', [1])[0]
start_response('200 OK', [('Content-type', 'text/plain')])
return [six.b('a is %s, body is %s' % (a, body))]