Adding namespace on integration tests + examples

Signed-off-by: Modular Magician <magic-modules@google.com>
This commit is contained in:
Alex Stephen 2019-09-30 22:08:25 +00:00 committed by Modular Magician
commit 516fada880
130 changed files with 570 additions and 570 deletions

View file

@ -14,7 +14,7 @@
# ----------------------------------------------------------------------------
# Pre-test setup
- name: create a disk
gcp_compute_disk:
google.cloud.gcp_compute_disk:
name: disk-instance
size_gb: 50
source_image: projects/ubuntu-os-cloud/global/images/family/ubuntu-1604-lts
@ -25,7 +25,7 @@
state: present
register: disk
- name: create a network
gcp_compute_network:
google.cloud.gcp_compute_network:
name: network-instance
project: "{{ gcp_project }}"
auth_kind: "{{ gcp_cred_kind }}"
@ -33,7 +33,7 @@
state: present
register: network
- name: create a address
gcp_compute_address:
google.cloud.gcp_compute_address:
name: address-instance
region: us-central1
project: "{{ gcp_project }}"
@ -42,7 +42,7 @@
state: present
register: address
- name: delete a instance
gcp_compute_instance:
google.cloud.gcp_compute_instance:
name: "{{ resource_name }}"
machine_type: n1-standard-1
disks:
@ -67,7 +67,7 @@
state: absent
#----------------------------------------------------------
- name: create a instance
gcp_compute_instance:
google.cloud.gcp_compute_instance:
name: "{{ resource_name }}"
machine_type: n1-standard-1
disks:
@ -112,7 +112,7 @@
- results['resources'] | length == 1
# ----------------------------------------------------------------------------
- name: create a instance that already exists
gcp_compute_instance:
google.cloud.gcp_compute_instance:
name: "{{ resource_name }}"
machine_type: n1-standard-1
disks:
@ -142,7 +142,7 @@
- result.changed == false
#----------------------------------------------------------
- name: delete a instance
gcp_compute_instance:
google.cloud.gcp_compute_instance:
name: "{{ resource_name }}"
machine_type: n1-standard-1
disks:
@ -187,7 +187,7 @@
- results['resources'] | length == 0
# ----------------------------------------------------------------------------
- name: delete a instance that does not exist
gcp_compute_instance:
google.cloud.gcp_compute_instance:
name: "{{ resource_name }}"
machine_type: n1-standard-1
disks:
@ -219,7 +219,7 @@
# Post-test teardown
# If errors happen, don't crash the playbook!
- name: delete a address
gcp_compute_address:
google.cloud.gcp_compute_address:
name: address-instance
region: us-central1
project: "{{ gcp_project }}"
@ -229,7 +229,7 @@
register: address
ignore_errors: true
- name: delete a network
gcp_compute_network:
google.cloud.gcp_compute_network:
name: network-instance
project: "{{ gcp_project }}"
auth_kind: "{{ gcp_cred_kind }}"
@ -238,7 +238,7 @@
register: network
ignore_errors: true
- name: delete a disk
gcp_compute_disk:
google.cloud.gcp_compute_disk:
name: disk-instance
size_gb: 50
source_image: projects/ubuntu-os-cloud/global/images/family/ubuntu-1604-lts