def test_create_script_perms(self):
"""this tests the create_script function (permissions).
"""
script_file = os.path.join(self.root, 'script')
# Test non-default mode (+x)
mode = (stat.S_IRUSR |
stat.S_IRGRP |
stat.S_IROTH)
utils.create_script(
script_file,
's6.run',
mode=mode,
user='testproid',
home='home',
shell='shell',
_alias={
's6_setuidgid': '/test/s6-setuidgid',
}
)
self.assertEqual(utils.os.stat(script_file).st_mode, 33060)
评论列表
文章目录