We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 66755cb commit 84db4a9Copy full SHA for 84db4a9
Lib/test/test_os.py
@@ -1131,8 +1131,8 @@ def test_mode(self):
1131
self.assertTrue(os.path.exists(path))
1132
self.assertTrue(os.path.isdir(path))
1133
if os.name != 'nt':
1134
- self.assertEqual(stat.S_IMODE(os.stat(path).st_mode), 0o555)
1135
- self.assertEqual(stat.S_IMODE(os.stat(parent).st_mode), 0o775)
+ self.assertEqual(os.stat(path).st_mode & 0o777, 0o555)
+ self.assertEqual(os.stat(parent).st_mode & 0o777, 0o775)
1136
1137
def test_exist_ok_existing_directory(self):
1138
path = os.path.join(support.TESTFN, 'dir1')
0 commit comments