def setUp(self):
super(TestSudoUID, self).setUp()
# Always ensure that SUDO_UID is not set in the environment.
self.useFixture(EnvironmentVariable("SUDO_UID"))
# We probably can't set EUID to anything we want in tests so we must
# capture calls that attempt to do so.
self.patch_autospec(utils, "seteuid")
评论列表
文章目录