802cc60242
Add a new `timeout` parameter to `vmware_guest_tools_wait`. Also, a functional test to cover the module.
47 lines
1.3 KiB
YAML
47 lines
1.3 KiB
YAML
# Test code for the vmware_guest_tools_wait module.
|
|
# Copyright: (c) 2017 Philippe Dellaert <philippe@dellaert.org>
|
|
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
|
|
|
|
- when: vcsim is not defined
|
|
block:
|
|
- import_role:
|
|
name: prepare_vmware_tests
|
|
vars:
|
|
setup_attach_host: true
|
|
setup_datastore: true
|
|
setup_dvs_portgroup: true
|
|
setup_dvswitch: true
|
|
|
|
- name: Create VMs
|
|
vmware_guest:
|
|
hostname: "{{ vcenter_hostname }}"
|
|
username: "{{ vcenter_username }}"
|
|
password: "{{ vcenter_password }}"
|
|
datacenter: "{{ dc1 }}"
|
|
validate_certs: no
|
|
folder: '/DC0/vm/F0'
|
|
name: test_vm1
|
|
state: poweredon
|
|
guest_id: centos7_64Guest
|
|
disk:
|
|
- size_gb: 1
|
|
type: thin
|
|
datastore: '{{ rw_datastore }}'
|
|
hardware:
|
|
version: latest
|
|
memory_mb: 1024
|
|
num_cpus: 1
|
|
scsi: paravirtual
|
|
cdrom:
|
|
type: iso
|
|
iso_path: "[{{ ro_datastore }}] fedora.iso"
|
|
networks:
|
|
- name: VM Network
|
|
|
|
- vmware_guest_tools_wait:
|
|
hostname: "{{ vcenter_hostname }}"
|
|
username: "{{ vcenter_username }}"
|
|
password: "{{ vcenter_password }}"
|
|
timeout: 800
|
|
validate_certs: no
|
|
name: test_vm1
|