https://github.com/python/cpython/commit/59edf12705ca574040af266e044c7af69b5a75dd
commit: 59edf12705ca574040af266e044c7af69b5a75dd
branch: main
author: Christoph Walcher <[email protected]>
committer: encukou <[email protected]>
date: 2025-09-08T15:42:54+02:00
summary:
gh-57911: Fix failing symlink test in tarfile (GH-138626)
files:
M Lib/test/test_tarfile.py
diff --git a/Lib/test/test_tarfile.py b/Lib/test/test_tarfile.py
index e5466c3bf2a5e8..9892005787c8a6 100644
--- a/Lib/test/test_tarfile.py
+++ b/Lib/test/test_tarfile.py
@@ -3694,7 +3694,7 @@ def setUpClass(cls):
else:
raise AssertionError('Could not determine link resolution')
else:
- cls.dotdot_resolves_early = True
+ cls.dotdot_resolves_early = False
@contextmanager
def check_context(self, tar, filter, *, check_flag=True):
@@ -3842,7 +3842,7 @@ def test_parent_symlink(self):
arc.add('current', symlink_to='.')
# effectively points to ./../
- if self.dotdot_resolves_early:
+ if self.dotdot_resolves_early and os_helper.can_symlink():
arc.add('parent', symlink_to='current/../..')
else:
arc.add('parent', symlink_to='current/..')
_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]