mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 08:58:59 +00:00
Merge pull request #25978 from alprs/fix-service_test_changes
Correct service state changes in test mode
This commit is contained in:
commit
584d608852
@ -299,7 +299,7 @@ def running(name, enable=None, sig=None, init_delay=None, **kwargs):
|
||||
if before_toggle_status:
|
||||
ret['comment'] = 'The service {0} is already running'.format(name)
|
||||
if __opts__['test']:
|
||||
ret['result'] = None
|
||||
ret['result'] = True
|
||||
return ret
|
||||
if enable is True and not before_toggle_enable_status:
|
||||
ret.update(_enable(name, None, **kwargs))
|
||||
@ -392,7 +392,7 @@ def dead(name, enable=None, sig=None, **kwargs):
|
||||
ret.update(_disable(name, None, **kwargs))
|
||||
return ret
|
||||
else:
|
||||
ret['result'] = None
|
||||
ret['result'] = True
|
||||
return ret
|
||||
|
||||
if __opts__['test']:
|
||||
|
Loading…
Reference in New Issue
Block a user