mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
commit
a3feba4a26
2 changed files with 3 additions and 3 deletions
|
@ -169,7 +169,7 @@ def present(name,
|
|||
return ret
|
||||
ret['changes'].update({'tags':
|
||||
{'old': tags,
|
||||
'new': new_tags}})
|
||||
'new': list(new_tags)}})
|
||||
try:
|
||||
existing_perms = __salt__['rabbitmq.list_user_permissions'](name, runas=runas)
|
||||
except CommandExecutionError as err:
|
||||
|
|
|
@ -79,7 +79,7 @@ class RabbitmqUserTestCase(TestCase):
|
|||
self.assertDictEqual(rabbitmq_user.present(name, force=True),
|
||||
ret)
|
||||
|
||||
changes = {'tags': {'new': set(['e', 'r', 's', 'u']), 'old': 'user'}}
|
||||
changes = {'tags': {'new': ['u', 's', 'r', 'e'], 'old': 'user'}}
|
||||
ret.update({'changes': changes})
|
||||
self.assertDictEqual(rabbitmq_user.present(name, tags=tag), ret)
|
||||
|
||||
|
@ -90,7 +90,7 @@ class RabbitmqUserTestCase(TestCase):
|
|||
|
||||
with patch.dict(rabbitmq_user.__opts__, {'test': False}):
|
||||
ret.update({'comment': '\'foo\' was configured.', 'result': True,
|
||||
'changes': {'tags': {'new': set(['e', 'r', 's', 'u']), 'old': 'user'}}})
|
||||
'changes': {'tags': {'new': ['u', 's', 'r', 'e'], 'old': 'user'}}})
|
||||
self.assertDictEqual(rabbitmq_user.present(name, tags=tag), ret)
|
||||
|
||||
# 'absent' function tests: 1
|
||||
|
|
Loading…
Add table
Reference in a new issue