From: Ned Deily Date: Thu, 15 Sep 2011 22:09:23 +0000 (-0700) Subject: Issue #12765: Fix packaging.test.test_database failures on OS X due X-Git-Tag: v3.3.0a1~1529 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=e30186bf4bfde9415229e58d25e467a5c6561239;p=thirdparty%2FPython%2Fcpython.git Issue #12765: Fix packaging.test.test_database failures on OS X due to unwarranted assumption about absolute paths: on OS X /var is a symlink to /private/var. (Also true for /etc and /tmp). --- diff --git a/Lib/packaging/tests/test_database.py b/Lib/packaging/tests/test_database.py index 5c95cdaa03be..b36e66d22da7 100644 --- a/Lib/packaging/tests/test_database.py +++ b/Lib/packaging/tests/test_database.py @@ -50,6 +50,7 @@ class FakeDistsMixin: tmpdir = tempfile.mkdtemp() self.addCleanup(shutil.rmtree, tmpdir) self.fake_dists_path = os.path.join(tmpdir, 'fake_dists') + self.fake_dists_path = os.path.realpath(self.fake_dists_path) fake_dists_src = os.path.abspath( os.path.join(os.path.dirname(__file__), 'fake_dists')) shutil.copytree(fake_dists_src, self.fake_dists_path)