mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 08:58:59 +00:00
Mock sys.platform so the test runs on Windows
This commit is contained in:
parent
4fdb5cb135
commit
8f2332f45c
@ -228,7 +228,8 @@ class TestProcess(TestCase):
|
||||
ret = salt.utils.process.daemonize_if({})
|
||||
self.assertEqual(None, ret)
|
||||
|
||||
with patch('salt.utils.process.daemonize'):
|
||||
with patch('salt.utils.process.daemonize'), \
|
||||
patch('sys.platform', 'linux2'):
|
||||
salt.utils.process.daemonize_if({})
|
||||
self.assertTrue(salt.utils.process.daemonize.called)
|
||||
# pylint: enable=assignment-from-none
|
||||
|
Loading…
Reference in New Issue
Block a user