mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-03-26 21:33:12 +00:00
Stop re-defining the argument spec in unit tests (#11235)
* Stop re-defining the argument spec in unit tests. * Shut up linter.
This commit is contained in:
@@ -589,7 +589,7 @@ def get_archive(module):
|
||||
return TarArchive(module)
|
||||
|
||||
|
||||
def main():
|
||||
def create_module() -> AnsibleModule:
|
||||
module = AnsibleModule(
|
||||
argument_spec=dict(
|
||||
path=dict(type="list", elements="path", required=True),
|
||||
@@ -603,6 +603,11 @@ def main():
|
||||
add_file_common_args=True,
|
||||
supports_check_mode=True,
|
||||
)
|
||||
return module
|
||||
|
||||
|
||||
def main():
|
||||
module = create_module()
|
||||
|
||||
check_mode = module.check_mode
|
||||
|
||||
|
||||
Reference in New Issue
Block a user