From: Berker Peksag Date: Tue, 21 May 2019 23:00:35 +0000 (+0300) Subject: bpo-36948: Fix test_urlopener_retrieve_file on Windows (GH-13476) X-Git-Tag: v3.8.0b1~265 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=2725cb01d7cbf5caecb51cc20d97ba324b09ce96;p=thirdparty%2FPython%2Fcpython.git bpo-36948: Fix test_urlopener_retrieve_file on Windows (GH-13476) --- diff --git a/Lib/test/test_urllib.py b/Lib/test/test_urllib.py index 74b19fbdcd8d..6b995fef8cb5 100644 --- a/Lib/test/test_urllib.py +++ b/Lib/test/test_urllib.py @@ -1470,7 +1470,8 @@ class URLopener_Tests(FakeHTTPMixin, unittest.TestCase): os.close(fd) fileurl = "file:" + urllib.request.pathname2url(tmpfile) filename, _ = urllib.request.URLopener().retrieve(fileurl) - self.assertEqual(filename, tmpfile) + # Some buildbots have TEMP folder that uses a lowercase drive letter. + self.assertEqual(os.path.normcase(filename), os.path.normcase(tmpfile)) @support.ignore_warnings(category=DeprecationWarning) def test_urlopener_retrieve_remote(self):