Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tidy up sanity checks ignore lines modules (batch 8) #2006

Merged
merged 7 commits into from
Mar 14, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions changelogs/fragments/2006-valmod-batch8.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
minor_changes:
- rax - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/2006).
- rax_cdb_user - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/2006).
- rax_scaling_group - elements of list parameters are now validated (https://github.com/ansible-collections/community.general/pull/2006).
6 changes: 4 additions & 2 deletions plugins/modules/cloud/rackspace/rax.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@
with this image
instance_ids:
type: list
elements: str
description:
- list of instance ids, currently only used when state='absent' to
remove instances
Expand All @@ -129,6 +130,7 @@
- Name to give the instance
networks:
type: list
elements: str
description:
- The network to attach to the instances. If specified, you must include
ALL networks including the public and private interfaces. Can be C(id)
Expand Down Expand Up @@ -810,11 +812,11 @@ def main():
flavor=dict(),
group=dict(),
image=dict(),
instance_ids=dict(type='list'),
instance_ids=dict(type='list', elements='str'),
key_name=dict(aliases=['keypair']),
meta=dict(type='dict', default={}),
name=dict(),
networks=dict(type='list', default=['public', 'private']),
networks=dict(type='list', elements='str', default=['public', 'private']),
service=dict(),
state=dict(default='present', choices=['present', 'absent']),
user_data=dict(no_log=True),
Expand Down
3 changes: 2 additions & 1 deletion plugins/modules/cloud/rackspace/rax_cdb_user.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
required: yes
databases:
type: list
elements: str
description:
- Name of the databases that the user can access
default: []
Expand Down Expand Up @@ -189,7 +190,7 @@ def main():
cdb_id=dict(type='str', required=True),
db_username=dict(type='str', required=True),
db_password=dict(type='str', required=True, no_log=True),
databases=dict(type='list', default=[]),
databases=dict(type='list', elements='str', default=[]),
host=dict(type='str', default='%'),
state=dict(default='present', choices=['present', 'absent'])
)
Expand Down
6 changes: 4 additions & 2 deletions plugins/modules/cloud/rackspace/rax_scaling_group.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
- key pair to use on the instance
loadbalancers:
type: list
elements: dict
description:
- List of load balancer C(id) and C(port) hashes
max_entities:
Expand All @@ -78,6 +79,7 @@
required: true
networks:
type: list
elements: str
description:
- The network to attach to the instances. If specified, you must include
ALL networks including the public and private interfaces. Can be C(id)
Expand Down Expand Up @@ -376,12 +378,12 @@ def main():
flavor=dict(required=True),
image=dict(required=True),
key_name=dict(),
loadbalancers=dict(type='list'),
loadbalancers=dict(type='list', elements='dict'),
meta=dict(type='dict', default={}),
min_entities=dict(type='int', required=True),
max_entities=dict(type='int', required=True),
name=dict(required=True),
networks=dict(type='list', default=['public', 'private']),
networks=dict(type='list', elements='str', default=['public', 'private']),
server_name=dict(required=True),
state=dict(default='present', choices=['present', 'absent']),
user_data=dict(no_log=True),
Expand Down
1 change: 1 addition & 0 deletions plugins/modules/cloud/smartos/smartos_image_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
manifest and 'published_date', 'published', 'source', 'clones',
and 'size'. More information can be found at U(https://smartos.org/man/1m/imgadm)
under 'imgadm list'.
type: str
'''

EXAMPLES = '''
Expand Down
6 changes: 1 addition & 5 deletions tests/sanity/ignore-2.10.txt
Original file line number Diff line number Diff line change
Expand Up @@ -65,14 +65,11 @@ plugins/modules/cloud/ovirt/ovirt_vmpool_facts.py validate-modules:doc-missing-t
plugins/modules/cloud/ovirt/ovirt_vmpool_facts.py validate-modules:parameter-list-no-elements
plugins/modules/cloud/rackspace/rax.py use-argspec-type-path # fix needed
plugins/modules/cloud/rackspace/rax.py validate-modules:doc-missing-type
plugins/modules/cloud/rackspace/rax.py validate-modules:parameter-list-no-elements
plugins/modules/cloud/rackspace/rax.py validate-modules:undocumented-parameter
plugins/modules/cloud/rackspace/rax_cdb_user.py validate-modules:parameter-list-no-elements
plugins/modules/cloud/rackspace/rax_files.py validate-modules:parameter-state-invalid-choice
plugins/modules/cloud/rackspace/rax_files_objects.py use-argspec-type-path
plugins/modules/cloud/rackspace/rax_mon_notification_plan.py validate-modules:parameter-list-no-elements
plugins/modules/cloud/rackspace/rax_scaling_group.py use-argspec-type-path # fix needed
plugins/modules/cloud/rackspace/rax_scaling_group.py validate-modules:parameter-list-no-elements
plugins/modules/cloud/rackspace/rax_scaling_group.py use-argspec-type-path # fix needed, expanduser() applied to dict values
plugins/modules/cloud/scaleway/scaleway_image_facts.py validate-modules:return-syntax-error
plugins/modules/cloud/scaleway/scaleway_image_info.py validate-modules:return-syntax-error
plugins/modules/cloud/scaleway/scaleway_ip_facts.py validate-modules:return-syntax-error
Expand All @@ -87,7 +84,6 @@ plugins/modules/cloud/scaleway/scaleway_snapshot_facts.py validate-modules:retur
plugins/modules/cloud/scaleway/scaleway_snapshot_info.py validate-modules:return-syntax-error
plugins/modules/cloud/scaleway/scaleway_volume_facts.py validate-modules:return-syntax-error
plugins/modules/cloud/scaleway/scaleway_volume_info.py validate-modules:return-syntax-error
plugins/modules/cloud/smartos/smartos_image_info.py validate-modules:doc-missing-type
plugins/modules/cloud/smartos/vmadm.py validate-modules:parameter-type-not-in-doc
plugins/modules/cloud/smartos/vmadm.py validate-modules:undocumented-parameter
plugins/modules/cloud/spotinst/spotinst_aws_elastigroup.py validate-modules:parameter-list-no-elements
Expand Down
6 changes: 1 addition & 5 deletions tests/sanity/ignore-2.11.txt
Original file line number Diff line number Diff line change
Expand Up @@ -64,14 +64,11 @@ plugins/modules/cloud/ovirt/ovirt_vmpool_facts.py validate-modules:doc-missing-t
plugins/modules/cloud/ovirt/ovirt_vmpool_facts.py validate-modules:parameter-list-no-elements
plugins/modules/cloud/rackspace/rax.py use-argspec-type-path # fix needed
plugins/modules/cloud/rackspace/rax.py validate-modules:doc-missing-type
plugins/modules/cloud/rackspace/rax.py validate-modules:parameter-list-no-elements
plugins/modules/cloud/rackspace/rax.py validate-modules:undocumented-parameter
plugins/modules/cloud/rackspace/rax_cdb_user.py validate-modules:parameter-list-no-elements
plugins/modules/cloud/rackspace/rax_files.py validate-modules:parameter-state-invalid-choice
plugins/modules/cloud/rackspace/rax_files_objects.py use-argspec-type-path
plugins/modules/cloud/rackspace/rax_mon_notification_plan.py validate-modules:parameter-list-no-elements
plugins/modules/cloud/rackspace/rax_scaling_group.py use-argspec-type-path # fix needed
plugins/modules/cloud/rackspace/rax_scaling_group.py validate-modules:parameter-list-no-elements
plugins/modules/cloud/rackspace/rax_scaling_group.py use-argspec-type-path # fix needed, expanduser() applied to dict values
plugins/modules/cloud/scaleway/scaleway_image_facts.py validate-modules:return-syntax-error
plugins/modules/cloud/scaleway/scaleway_image_info.py validate-modules:return-syntax-error
plugins/modules/cloud/scaleway/scaleway_ip_facts.py validate-modules:return-syntax-error
Expand All @@ -86,7 +83,6 @@ plugins/modules/cloud/scaleway/scaleway_snapshot_facts.py validate-modules:retur
plugins/modules/cloud/scaleway/scaleway_snapshot_info.py validate-modules:return-syntax-error
plugins/modules/cloud/scaleway/scaleway_volume_facts.py validate-modules:return-syntax-error
plugins/modules/cloud/scaleway/scaleway_volume_info.py validate-modules:return-syntax-error
plugins/modules/cloud/smartos/smartos_image_info.py validate-modules:doc-missing-type
plugins/modules/cloud/smartos/vmadm.py validate-modules:parameter-type-not-in-doc
plugins/modules/cloud/smartos/vmadm.py validate-modules:undocumented-parameter
plugins/modules/cloud/spotinst/spotinst_aws_elastigroup.py validate-modules:parameter-list-no-elements
Expand Down
3 changes: 1 addition & 2 deletions tests/sanity/ignore-2.9.txt
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ plugins/modules/cloud/rackspace/rax.py use-argspec-type-path
plugins/modules/cloud/rackspace/rax.py validate-modules:doc-missing-type
plugins/modules/cloud/rackspace/rax.py validate-modules:undocumented-parameter
plugins/modules/cloud/rackspace/rax_files_objects.py use-argspec-type-path
plugins/modules/cloud/rackspace/rax_scaling_group.py use-argspec-type-path
plugins/modules/cloud/rackspace/rax_scaling_group.py use-argspec-type-path # fix needed, expanduser() applied to dict values
plugins/modules/cloud/scaleway/scaleway_image_facts.py validate-modules:deprecation-mismatch
plugins/modules/cloud/scaleway/scaleway_image_facts.py validate-modules:invalid-documentation
plugins/modules/cloud/scaleway/scaleway_image_facts.py validate-modules:return-syntax-error
Expand Down Expand Up @@ -126,7 +126,6 @@ plugins/modules/cloud/scaleway/scaleway_volume_facts.py validate-modules:depreca
plugins/modules/cloud/scaleway/scaleway_volume_facts.py validate-modules:invalid-documentation
plugins/modules/cloud/scaleway/scaleway_volume_facts.py validate-modules:return-syntax-error
plugins/modules/cloud/scaleway/scaleway_volume_info.py validate-modules:return-syntax-error
plugins/modules/cloud/smartos/smartos_image_info.py validate-modules:doc-missing-type
plugins/modules/cloud/smartos/vmadm.py validate-modules:parameter-type-not-in-doc
plugins/modules/cloud/smartos/vmadm.py validate-modules:undocumented-parameter
plugins/modules/cloud/spotinst/spotinst_aws_elastigroup.py validate-modules:parameter-type-not-in-doc
Expand Down