diff --git a/roles/info/tasks/main.yml b/roles/info/tasks/main.yml index 04c47095..2646aca1 100644 --- a/roles/info/tasks/main.yml +++ b/roles/info/tasks/main.yml @@ -39,6 +39,6 @@ license: "{{ __license.licenses | default([]) }}" appliance: "{{ __appliance.appliance | default({}) }}" guest: "{{ __guests.guests | default([]) }}" - cluster: "{{ _clusters_info.results | default([]) | map(attribute='clusters') }}" + cluster: "{{ __clusters_info.results | default([]) | map(attribute='clusters') }}" storage: "{{ __storage_policy.spbm_profiles | default([]) }}" when: info_expose_outputs_as_variable diff --git a/tests/integration/targets/vmware_ops_info_test/tasks/main.yml b/tests/integration/targets/vmware_ops_info_test/tasks/main.yml index 45be9659..a3865344 100644 --- a/tests/integration/targets/vmware_ops_info_test/tasks/main.yml +++ b/tests/integration/targets/vmware_ops_info_test/tasks/main.yml @@ -12,8 +12,8 @@ - vmware_ops_info_outputs.cluster is defined - vmware_ops_info_outputs.storage is defined - - (vmware_ops_info_outputs.appliance | length | bool) == info_appliance - - (vmware_ops_info_outputs.license | length | bool) == info_license - - (vmware_ops_info_outputs.guest | length | bool) == info_guest - - (vmware_ops_info_outputs.cluster | length | bool) == info_cluster - - (vmware_ops_info_outputs.storage | length | bool) == info_storage + - (vmware_ops_info_outputs.appliance.keys() | length > 0) == info_appliance + - (vmware_ops_info_outputs.license | length > 0) == info_license + - (vmware_ops_info_outputs.guest | length > 0) == info_guest + - (vmware_ops_info_outputs.cluster | length > 0) == info_cluster + - (vmware_ops_info_outputs.storage | length > 0) == info_storage