mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 08:58:59 +00:00
Replace usage of deprecated expr_form in tests
This commit is contained in:
parent
a74fc5bd47
commit
94a16ada7b
@ -1404,7 +1404,7 @@ class TestDaemon(object):
|
||||
|
||||
def __client_job_running(self, targets, jid):
|
||||
running = self.client.cmd(
|
||||
list(targets), 'saltutil.running', expr_form='list'
|
||||
list(targets), 'saltutil.running', tgt_type='list'
|
||||
)
|
||||
return [
|
||||
k for (k, v) in six.iteritems(running) if v and v[0]['jid'] == jid
|
||||
@ -1443,7 +1443,7 @@ class TestDaemon(object):
|
||||
|
||||
try:
|
||||
responses = self.client.cmd(
|
||||
list(expected_connections), 'test.ping', expr_form='list',
|
||||
list(expected_connections), 'test.ping', tgt_type='list',
|
||||
)
|
||||
# we'll get this exception if the master process hasn't finished starting yet
|
||||
except SaltClientError:
|
||||
@ -1503,7 +1503,7 @@ class TestDaemon(object):
|
||||
syncing = set(targets)
|
||||
jid_info = self.client.run_job(
|
||||
list(targets), 'saltutil.sync_{0}'.format(modules_kind),
|
||||
expr_form='list',
|
||||
tgt_type='list',
|
||||
timeout=999999999999999,
|
||||
)
|
||||
|
||||
|
@ -58,20 +58,20 @@ class LocalClientTestCase(TestCase,
|
||||
self.client.cmd_subset('*', 'first.func', sub=1, cli=True)
|
||||
try:
|
||||
cmd_cli_mock.assert_called_with(['minion2'], 'first.func', (), progress=False,
|
||||
kwarg=None, expr_form='list',
|
||||
kwarg=None, tgt_type='list',
|
||||
ret='')
|
||||
except AssertionError:
|
||||
cmd_cli_mock.assert_called_with(['minion1'], 'first.func', (), progress=False,
|
||||
kwarg=None, expr_form='list',
|
||||
kwarg=None, tgt_type='list',
|
||||
ret='')
|
||||
self.client.cmd_subset('*', 'first.func', sub=10, cli=True)
|
||||
try:
|
||||
cmd_cli_mock.assert_called_with(['minion2', 'minion1'], 'first.func', (), progress=False,
|
||||
kwarg=None, expr_form='list',
|
||||
kwarg=None, tgt_type='list',
|
||||
ret='')
|
||||
except AssertionError:
|
||||
cmd_cli_mock.assert_called_with(['minion1', 'minion2'], 'first.func', (), progress=False,
|
||||
kwarg=None, expr_form='list',
|
||||
kwarg=None, tgt_type='list',
|
||||
ret='')
|
||||
|
||||
@skipIf(NOT_ZMQ, 'This test only works with ZeroMQ')
|
||||
@ -88,7 +88,7 @@ class LocalClientTestCase(TestCase,
|
||||
# Do we raise an exception if the nodegroup can't be matched?
|
||||
self.assertRaises(SaltInvocationError,
|
||||
self.client.pub,
|
||||
'non_existent_group', 'test.ping', expr_form='nodegroup')
|
||||
'non_existent_group', 'test.ping', tgt_type='nodegroup')
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
Loading…
Reference in New Issue
Block a user