summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_urlparse.py
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2002-10-14 19:59:54 (GMT)
committerGuido van Rossum <guido@python.org>2002-10-14 19:59:54 (GMT)
commitbbc0568a5c7d3849a22c78d545823a4b952c0933 (patch)
treec308697f61aeeaa5355147e63b144e97a75161bb /Lib/test/test_urlparse.py
parent6e75364cbe191710c056c437f2f0e29546625470 (diff)
downloadcpython-bbc0568a5c7d3849a22c78d545823a4b952c0933.zip
cpython-bbc0568a5c7d3849a22c78d545823a4b952c0933.tar.gz
cpython-bbc0568a5c7d3849a22c78d545823a4b952c0933.tar.bz2
Fix for 1.33: urlsplit() should only add '//' if scheme != ''.
Will add test and backport.
Diffstat (limited to 'Lib/test/test_urlparse.py')
-rw-r--r--Lib/test/test_urlparse.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/Lib/test/test_urlparse.py b/Lib/test/test_urlparse.py
index b821879..39f50e4 100644
--- a/Lib/test/test_urlparse.py
+++ b/Lib/test/test_urlparse.py
@@ -27,7 +27,12 @@ class UrlParseTestCase(unittest.TestCase):
self.assertEqual(result2, url)
def checkJoin(self, base, relurl, expected):
- self.assertEqual(urlparse.urljoin(base, relurl), expected)
+ self.assertEqual(urlparse.urljoin(base, relurl), expected,
+ (base, relurl, expected))
+
+ def test_unparse_parse(self):
+ for u in ['Python', './Python']:
+ self.assertEqual(urlparse.urlunparse(urlparse.urlparse(u)), u)
def test_RFC1808(self):
# "normal" cases from RFC 1808: