mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
change arg to mocked to try test suite collision fix
This commit is contained in:
parent
2fbdcda703
commit
f9480f66d8
2 changed files with 9 additions and 9 deletions
|
@ -549,12 +549,12 @@ def highstate(test=None,
|
|||
pillar,
|
||||
kwargs.get('__pub_jid'),
|
||||
proxy=__proxy__,
|
||||
mock=kwargs.get('mock', False))
|
||||
mocked=kwargs.get('mock', False))
|
||||
except NameError:
|
||||
st_ = salt.state.HighState(opts,
|
||||
pillar,
|
||||
kwargs.get('__pub_jid'),
|
||||
mock=kwargs.get('mock', False))
|
||||
mocked=kwargs.get('mock', False))
|
||||
|
||||
st_.push_active()
|
||||
try:
|
||||
|
@ -717,12 +717,12 @@ def sls(mods,
|
|||
pillar,
|
||||
kwargs.get('__pub_jid'),
|
||||
proxy=__proxy__,
|
||||
mock=kwargs.get('mock', False))
|
||||
mocked=kwargs.get('mock', False))
|
||||
except NameError:
|
||||
st_ = salt.state.HighState(opts,
|
||||
pillar,
|
||||
kwargs.get('__pub_jid'),
|
||||
mock=kwargs.get('mock', False))
|
||||
mocked=kwargs.get('mock', False))
|
||||
|
||||
umask = os.umask(0o77)
|
||||
if kwargs.get('cache'):
|
||||
|
|
|
@ -618,7 +618,7 @@ class State(object):
|
|||
'''
|
||||
Class used to execute salt states
|
||||
'''
|
||||
def __init__(self, opts, pillar=None, jid=None, proxy=None, mock=False):
|
||||
def __init__(self, opts, pillar=None, jid=None, proxy=None, mocked=False):
|
||||
if 'grains' not in opts:
|
||||
opts['grains'] = salt.loader.grains(opts)
|
||||
self.opts = opts
|
||||
|
@ -634,7 +634,7 @@ class State(object):
|
|||
self.jid = jid
|
||||
self.instance_id = str(id(self))
|
||||
self.inject_globals = {}
|
||||
self.mock = mock
|
||||
self.mocked = mocked
|
||||
|
||||
def _gather_pillar(self):
|
||||
'''
|
||||
|
@ -1617,7 +1617,7 @@ class State(object):
|
|||
|
||||
if 'result' not in ret or ret['result'] is False:
|
||||
self.states.inject_globals = inject_globals
|
||||
if self.mock:
|
||||
if self.mocked:
|
||||
ret = mock_ret(cdata)
|
||||
else:
|
||||
ret = self.states[cdata['full']](*cdata['args'],
|
||||
|
@ -3193,11 +3193,11 @@ class HighState(BaseHighState):
|
|||
# a stack of active HighState objects during a state.highstate run
|
||||
stack = []
|
||||
|
||||
def __init__(self, opts, pillar=None, jid=None, proxy=None, mock=False):
|
||||
def __init__(self, opts, pillar=None, jid=None, proxy=None, mocked=False):
|
||||
self.opts = opts
|
||||
self.client = salt.fileclient.get_file_client(self.opts)
|
||||
BaseHighState.__init__(self, opts)
|
||||
self.state = State(self.opts, pillar, jid, proxy=proxy, mock=mock)
|
||||
self.state = State(self.opts, pillar, jid, proxy=proxy, mocked=mocked)
|
||||
self.matcher = salt.minion.Matcher(self.opts)
|
||||
|
||||
# tracks all pydsl state declarations globally across sls files
|
||||
|
|
Loading…
Add table
Reference in a new issue