Fix test_sys.test_stdlib_dir() when Python is built outside the
source tree: compare normalized paths.
if marker and not os.path.exists(marker):
marker = None
expected = os.path.dirname(marker) if marker else None
- actual = sys._stdlib_dir
- self.assertEqual(actual, expected)
+ self.assertEqual(os.path.normpath(sys._stdlib_dir),
+ os.path.normpath(expected))
@test.support.cpython_only
--- /dev/null
+Fix test_sys.test_stdlib_dir() when Python is built outside the source tree:
+compare normalized paths. Patch by Victor Stinner.