mirror of
https://github.com/django/django.git
synced 2025-08-04 10:59:45 +00:00
Fixed #23333 -- Made urlsafe_base64_decode() return proper type on Python 3.
This commit is contained in:
parent
f9c7732e96
commit
03d89168a2
2 changed files with 8 additions and 2 deletions
|
@ -119,6 +119,12 @@ class TestUtilsHttp(unittest.TestCase):
|
|||
'/url%20with%20spaces/'):
|
||||
self.assertTrue(http.is_safe_url(good_url, host='testserver'), "%s should be allowed" % good_url)
|
||||
|
||||
def test_urlsafe_base64_roundtrip(self):
|
||||
bytestring = b'foo'
|
||||
encoded = http.urlsafe_base64_encode(bytestring)
|
||||
decoded = http.urlsafe_base64_decode(encoded)
|
||||
self.assertEqual(bytestring, decoded)
|
||||
|
||||
|
||||
class ETagProcessingTests(unittest.TestCase):
|
||||
def test_parsing(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue