gh-90473: Make chmod a dummy on WASI, skip chmod tests (GH-93534)

WASI does not have the ``chmod(2)`` syscall yet.
This commit is contained in:
Christian Heimes 2022-06-06 19:24:11 +02:00 committed by GitHub
parent 56b5daf159
commit 22fed605e0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
20 changed files with 81 additions and 5 deletions

View file

@ -113,6 +113,7 @@ class TestFilemode:
else:
self.assertFalse(func(mode))
@os_helper.skip_unless_working_chmod
def test_mode(self):
with open(TESTFN, 'w'):
pass
@ -151,6 +152,7 @@ class TestFilemode:
self.assertEqual(self.statmod.S_IFMT(st_mode),
self.statmod.S_IFREG)
@os_helper.skip_unless_working_chmod
def test_directory(self):
os.mkdir(TESTFN)
os.chmod(TESTFN, 0o700)