[Python-checkins] cpython (2.7): Issue #17248: Fix os.*chown() testing when user is in root group.
serhiy.storchaka
python-checkins at python.org
Thu Feb 21 13:38:03 CET 2013
http://hg.python.org/cpython/rev/7a9ea3d08f51
changeset: 82296:7a9ea3d08f51
branch: 2.7
parent: 82292:943ea41d3ceb
user: Serhiy Storchaka <storchaka at gmail.com>
date: Thu Feb 21 14:33:45 2013 +0200
summary:
Issue #17248: Fix os.*chown() testing when user is in root group.
files:
Lib/test/test_posix.py | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Lib/test/test_posix.py b/Lib/test/test_posix.py
--- a/Lib/test/test_posix.py
+++ b/Lib/test/test_posix.py
@@ -271,7 +271,7 @@
check_stat(uid, gid)
self.assertRaises(OSError, chown_func, first_param, 0, -1)
check_stat(uid, gid)
- if gid != 0:
+ if 0 not in os.getgroups():
self.assertRaises(OSError, chown_func, first_param, -1, 0)
check_stat(uid, gid)
# test illegal types
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list