mirror of
https://github.com/python/cpython.git
synced 2025-08-31 14:07:50 +00:00
When /tmp has certain sticky bits set, newly created subdirectories
inherit those bits, causing the test_mkdtemp.test_mode() test to fail. Remove those before comparing the actual mode to the expected mode.
This commit is contained in:
parent
862b46bbc1
commit
59db96f2a3
1 changed files with 1 additions and 0 deletions
|
@ -479,6 +479,7 @@ class test_mkdtemp(TC):
|
|||
dir = self.do_create()
|
||||
try:
|
||||
mode = stat.S_IMODE(os.stat(dir).st_mode)
|
||||
mode &= 0777 # Mask off sticky bits inherited from /tmp
|
||||
expected = 0700
|
||||
if sys.platform in ('win32', 'os2emx', 'mac'):
|
||||
# There's no distinction among 'user', 'group' and 'world';
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue