Skip to content

Commit eb95cf6

Browse files
committed
tests: better check for lchmod test
1 parent c14d656 commit eb95cf6

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

upath/tests/test_extensions.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,8 @@ def test_cwd(self):
132132
type(self.path).cwd()
133133

134134
def test_lchmod(self):
135-
if hasattr(os, "lchmod") and os.lchmod in os.supports_follow_symlinks:
135+
# see: https://github.com/python/cpython/issues/108660#issuecomment-1854645898
136+
if hasattr(os, "lchmod") or os.chmod in os.supports_follow_symlinks:
136137
cm = nullcontext()
137138
else:
138139
cm = pytest.raises(UnsupportedOperation)

0 commit comments

Comments
 (0)