File tree Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -359,13 +359,14 @@ def test_expanduser_pwd(self):
359359 "no home directory on VxWorks" )
360360 def test_expanduser_pwd2 (self ):
361361 pwd = import_helper .import_module ('pwd' )
362- for e in pwd .getpwall ():
363- name = e .pw_name
364- home = e .pw_dir
362+ for entry in pwd .getpwall ():
363+ name = entry .pw_name
364+ home = entry .pw_dir
365365 home = home .rstrip ('/' ) or '/'
366- self .assertEqual (posixpath .expanduser ('~' + name ), home )
367- self .assertEqual (posixpath .expanduser (os .fsencode ('~' + name )),
368- os .fsencode (home ))
366+ with self .subTest (pwd = entry ):
367+ self .assertEqual (posixpath .expanduser ('~' + name ), home )
368+ self .assertEqual (posixpath .expanduser (os .fsencode ('~' + name )),
369+ os .fsencode (home ))
369370
370371 NORMPATH_CASES = [
371372 ("" , "." ),
You can’t perform that action at this time.
0 commit comments