summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2015-01-10 08:00:20 (GMT)
committerVictor Stinner <victor.stinner@gmail.com>2015-01-10 08:00:20 (GMT)
commite9694398625f2c82c078aed4d891987474a87e0e (patch)
treefd24e2af6c4dfbac83317ec2a21992ec191631be /Lib
parent645f896536e09baaa5151007b93931461509d5ca (diff)
downloadcpython-e9694398625f2c82c078aed4d891987474a87e0e.zip
cpython-e9694398625f2c82c078aed4d891987474a87e0e.tar.gz
cpython-e9694398625f2c82c078aed4d891987474a87e0e.tar.bz2
Issue #19776: Fix test_pathlib.test_expanduser()
Skip users with an empty home directory.
Diffstat (limited to 'Lib')
-rw-r--r--Lib/test/test_pathlib.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/test_pathlib.py b/Lib/test/test_pathlib.py
index 1beb84d..2e97a5e 100644
--- a/Lib/test/test_pathlib.py
+++ b/Lib/test/test_pathlib.py
@@ -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')