summaryrefslogtreecommitdiffstats
path: root/test/integration
diff options
context:
space:
mode:
authorDiane Wang <41371902+Tomorrow9@users.noreply.github.com>2019-08-28 19:04:30 +0200
committerGonéri Le Bouder <goneri@lebouder.net>2019-08-28 19:04:30 +0200
commitd987dca2b1a2ea695c726828526b038fc184580b (patch)
tree69b77c40239e120510d9261eecdcb5d2418075a2 /test/integration
parentFix CI test result placement. (diff)
downloadansible-d987dca2b1a2ea695c726828526b038fc184580b.tar.xz
ansible-d987dca2b1a2ea695c726828526b038fc184580b.zip
VMware: vmware_guest_screenshot module fix get_parent_datacenter issue (#60626)
Fix get_parent_datacenter not found issue, and change "local_path" parameter to "path" type. closes: #60565
Diffstat (limited to 'test/integration')
-rw-r--r--test/integration/targets/vmware_guest_screenshot/tasks/main.yml14
1 files changed, 7 insertions, 7 deletions
diff --git a/test/integration/targets/vmware_guest_screenshot/tasks/main.yml b/test/integration/targets/vmware_guest_screenshot/tasks/main.yml
index 7a29538f29..30ccf6bfde 100644
--- a/test/integration/targets/vmware_guest_screenshot/tasks/main.yml
+++ b/test/integration/targets/vmware_guest_screenshot/tasks/main.yml
@@ -11,13 +11,15 @@
setup_datastore: true
setup_virtualmachines: true
- - name: set state to poweroff on all VMs
+ - name: set VM state to powered on
vmware_guest:
validate_certs: False
hostname: "{{ vcenter_hostname }}"
username: "{{ vcenter_username }}"
password: "{{ vcenter_password }}"
- name: "{{ virtual_machines_in_cluster[0].name }}"
+ datacenter: "{{ dc1 }}"
+ folder: "{{ virtual_machines[0].folder }}"
+ name: "{{ virtual_machines[0].name }}"
state: poweredon
- name: take screenshot of virtual machine's console
@@ -26,9 +28,7 @@
hostname: "{{ vcenter_hostname }}"
username: "{{ vcenter_username }}"
password: "{{ vcenter_password }}"
- name: "{{ virtual_machines_in_cluster[0].name }}"
- # Note: set the datacenter key because of https://github.com/ansible/ansible/issues/60565
- datacenter: "{{ dc1 }}"
+ name: "{{ virtual_machines[0].name }}"
register: take_screenshot
- debug: var=take_screenshot
- name: assert the screenshot captured
@@ -42,10 +42,10 @@
hostname: "{{ vcenter_hostname }}"
username: "{{ vcenter_username }}"
password: "{{ vcenter_password }}"
- name: "{{ virtual_machines_in_cluster[0].name }}"
+ name: "{{ virtual_machines[0].name }}"
local_path: "/tmp/screenshot_test.png"
- # Note: set the datacenter key because of https://github.com/ansible/ansible/issues/60565
datacenter: "{{ dc1 }}"
+ folder: "{{ virtual_machines[0].folder }}"
register: take_screenshot
- debug: var=take_screenshot
- name: assert the screenshot captured