Add support for credential_type in tower_credential module (#3820)

* Add support for credential_type

* Finish up credential_type parameter with tests

* make inputs mutually exclusive with other params

* Test credential type with dict input
This commit is contained in:
Alan Rominger
2019-10-22 14:39:27 -04:00
committed by Ryan Petrello
parent ab6322a8f7
commit 70269d9a0d
5 changed files with 223 additions and 17 deletions

View File

@@ -98,8 +98,8 @@ class TowerModule(AnsibleModule):
)
args.update(argument_spec)
mutually_exclusive = kwargs.get('mutually_exclusive', [])
kwargs['mutually_exclusive'] = mutually_exclusive.extend((
kwargs.setdefault('mutually_exclusive', [])
kwargs['mutually_exclusive'].extend((
('tower_config_file', 'tower_host'),
('tower_config_file', 'tower_username'),
('tower_config_file', 'tower_password'),