Issue #19776: Fix test_pathlib.test_expanduser()
Skip users with an empty home directory.
This commit is contained in:
parent
645f896536
commit
e969439862
@ -1983,7 +1983,7 @@ class PosixPathTest(_BasePathTest, unittest.TestCase):
|
||||
for pwdent in pwd.getpwall():
|
||||
othername = pwdent.pw_name
|
||||
otherhome = pwdent.pw_dir.rstrip('/')
|
||||
if othername != username:
|
||||
if othername != username and otherhome:
|
||||
break
|
||||
|
||||
p1 = P('~/Documents')
|
||||
|
Loading…
x
Reference in New Issue
Block a user