Kaydet (Commit) f516388d authored tarafından R David Murray's avatar R David Murray

#17472: add tests for a couple of untested methods in urllib.urlparse.

Original patch by Daniel Wozniak.
üst 2b6c26eb
......@@ -847,6 +847,14 @@ class UrlParseTestCase(unittest.TestCase):
self.assertEqual(p1.path, '863-1234')
self.assertEqual(p1.params, 'phone-context=+1-914-555')
def test_unwrap(self):
url = urllib.parse.unwrap('<URL:type://host/path>')
self.assertEqual(url, 'type://host/path')
def test_Quoter_repr(self):
quoter = urllib.parse.Quoter(urllib.parse._ALWAYS_SAFE)
self.assertIn('Quoter', repr(quoter))
def test_main():
support.run_unittest(UrlParseTestCase)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment