Claudiu Popa added the comment: I think you can skip the entire test class if os.chown is not available. Also, maybe you can move the obtaining of groups and users in setUpClass? Also, in
+ with self.assertRaises(PermissionError) as cx: + os.chown(support.TESTFN, uid_1, gid) + os.chown(support.TESTFN, uid_2, gid) if the first os.chown will raise the PermissionError, the second one won't be called, maybe that's not what you intended to do. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue20069> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com