diff options
Diffstat (limited to 'Lib/test/test_urllib.py')
| -rw-r--r-- | Lib/test/test_urllib.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/test/test_urllib.py b/Lib/test/test_urllib.py index 5084486..bffbb0a 100644 --- a/Lib/test/test_urllib.py +++ b/Lib/test/test_urllib.py @@ -733,7 +733,7 @@ FF class QuotingTests(unittest.TestCase): r"""Tests for urllib.quote() and urllib.quote_plus() - According to RFC 2396 (Uniform Resource Identifiers), to escape a + According to RFC 3986 (Uniform Resource Identifiers), to escape a character you write it as '%' + <2 character US-ASCII hex value>. The Python code of ``'%' + hex(ord(<character>))[2:]`` escapes a character properly. Case does not matter on the hex letters. @@ -761,7 +761,7 @@ class QuotingTests(unittest.TestCase): do_not_quote = '' .join(["ABCDEFGHIJKLMNOPQRSTUVWXYZ", "abcdefghijklmnopqrstuvwxyz", "0123456789", - "_.-"]) + "_.-~"]) result = urllib.parse.quote(do_not_quote) self.assertEqual(do_not_quote, result, "using quote(): %r != %r" % (do_not_quote, result)) |
