summaryrefslogtreecommitdiff
path: root/test_requests.py
diff options
context:
space:
mode:
Diffstat (limited to 'test_requests.py')
-rwxr-xr-xtest_requests.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/test_requests.py b/test_requests.py
index 4fccc346..ae879cd1 100755
--- a/test_requests.py
+++ b/test_requests.py
@@ -591,6 +591,12 @@ class RequestsTestCase(unittest.TestCase):
assert resp.json()['headers'][
'Dummy-Auth-Test'] == 'dummy-auth-test-ok'
+ def test_prepare_request_with_bytestring_url(self):
+ req = requests.Request('GET', b'https://httpbin.org/')
+ s = requests.Session()
+ prep = s.prepare_request(req)
+ assert prep.url == "https://httpbin.org/"
+
def test_links(self):
r = requests.Response()
r.headers = {