Fix logic for non-root

This commit is contained in:
twangboy 2018-06-12 17:45:19 -06:00
parent 2d2534a688
commit 0e99dd741c
No known key found for this signature in database
GPG Key ID: 93FF3BDEB278C9EB

View File

@ -1065,9 +1065,9 @@ class DaemonMixInTestCase(TestCase):
'''
if salt.utils.platform.is_windows():
patch_args = ('salt.utils.win_functions.is_admin',
MagicMock(return_value=True))
MagicMock(return_value=False))
else:
patch_args = ('os.getuid', MagicMock(return_value=0))
patch_args = ('os.getuid', MagicMock(return_value=1000))
with patch(*patch_args):
self.daemon_mixin._mixin_before_exit()