mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 12:50:22 -07:00
Return commands instead of command (#24061)
Ok, so for openvswitch_db in particular we just return one command but in the sake of consistency and code re-use, let's return a list of "commands", even if it's just one.
This commit is contained in:
parent
9456f93ea8
commit
2716fad38f
3 changed files with 20 additions and 19 deletions
|
@ -65,7 +65,7 @@ class AnsibleFailJson(Exception):
|
|||
class TestOpenVSwitchModule(unittest.TestCase):
|
||||
|
||||
def execute_module(self, failed=False, changed=False,
|
||||
command=None, test_name=None):
|
||||
commands=None, test_name=None):
|
||||
|
||||
self.load_fixtures(test_name)
|
||||
|
||||
|
@ -76,8 +76,8 @@ class TestOpenVSwitchModule(unittest.TestCase):
|
|||
result = self.changed(changed)
|
||||
self.assertEqual(result['changed'], changed, result)
|
||||
|
||||
if command:
|
||||
self.assertEqual(command, result['command'], result['command'])
|
||||
if commands:
|
||||
self.assertEqual(commands, result['commands'], result['commands'])
|
||||
|
||||
return result
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue