[Python-checkins] bpo-32033: Fix test_pwd failures on Android (GH-19502)

Zackery Spytz webhook-mailer at python.org
Tue Apr 14 14:11:51 EDT 2020


https://github.com/python/cpython/commit/96515e9f6785328c52ebc5d4ce60e0087a9adc2d
commit: 96515e9f6785328c52ebc5d4ce60e0087a9adc2d
branch: master
author: Zackery Spytz <zspytz at gmail.com>
committer: GitHub <noreply at github.com>
date: 2020-04-14T20:11:46+02:00
summary:

bpo-32033: Fix test_pwd failures on Android (GH-19502)

files:
M Lib/test/test_pwd.py

diff --git a/Lib/test/test_pwd.py b/Lib/test/test_pwd.py
index c13a7c9294f98..85740cecd8229 100644
--- a/Lib/test/test_pwd.py
+++ b/Lib/test/test_pwd.py
@@ -21,7 +21,7 @@ def test_values(self):
             self.assertEqual(e[3], e.pw_gid)
             self.assertIsInstance(e.pw_gid, int)
             self.assertEqual(e[4], e.pw_gecos)
-            self.assertIsInstance(e.pw_gecos, str)
+            self.assertIn(type(e.pw_gecos), (str, type(None)))
             self.assertEqual(e[5], e.pw_dir)
             self.assertIsInstance(e.pw_dir, str)
             self.assertEqual(e[6], e.pw_shell)



More information about the Python-checkins mailing list