summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorHasan Ramezani <hasan.r67@gmail.com>2020-11-18 21:50:44 +0100
committerGitHub <noreply@github.com>2020-11-18 14:50:44 -0600
commit897d5aab0d87ea1ab86b240603ee95103eb74fa5 (patch)
tree30b9d4918aede41e07ca4210ee2952add690600a /test
parent089e46663ea5820790a8e243220b815d7421c62c (diff)
downloadurllib3-897d5aab0d87ea1ab86b240603ee95103eb74fa5.tar.gz
Remove Python 2 branches, HTTPHeaderDict.from_httplib
Diffstat (limited to 'test')
-rw-r--r--test/test_util.py9
-rw-r--r--test/with_dummyserver/test_socketlevel.py3
2 files changed, 1 insertions, 11 deletions
diff --git a/test/test_util.py b/test/test_util.py
index cfb4fa75..56d93bb1 100644
--- a/test/test_util.py
+++ b/test/test_util.py
@@ -255,15 +255,6 @@ class TestUtil:
"http://foo:bar@localhost/",
Url("http", auth="foo:bar", host="localhost", path="/"),
),
- # Unicode type (Python 2.x)
- (
- "http://foo:bar@localhost/",
- Url("http", auth="foo:bar", host="localhost", path="/"),
- ),
- (
- "http://foo:bar@localhost/",
- Url("http", auth="foo:bar", host="localhost", path="/"),
- ),
]
non_round_tripping_parse_url_host_map = [
diff --git a/test/with_dummyserver/test_socketlevel.py b/test/with_dummyserver/test_socketlevel.py
index 7c476b27..97788bf7 100644
--- a/test/with_dummyserver/test_socketlevel.py
+++ b/test/with_dummyserver/test_socketlevel.py
@@ -1414,8 +1414,7 @@ class TestSSL(SocketDummyServerTestCase):
def is_closed_socket(sock):
try:
- sock.settimeout(SHORT_TIMEOUT) # Python 3
- sock.recv(1) # Python 2
+ sock.settimeout(SHORT_TIMEOUT)
except OSError:
return True
return False