hcloud_networ_info: be more resilient is network already exists
We may already have an existing network or subnet. This commit ensures
we don't raise an error in this case.
e.g: https://app.shippable.com/github/ansible/ansible/runs/143559/145/tests
(cherry picked from commit 459677877a
)
This commit is contained in:
parent
51b8daa64d
commit
997f272c4e
1 changed files with 3 additions and 3 deletions
|
@ -52,9 +52,9 @@
|
|||
- name: verify test gather hcloud network info in check mode
|
||||
assert:
|
||||
that:
|
||||
- hcloud_network.hcloud_network_info | selectattr('name','equalto','{{ hcloud_network_name }}') | list | count == 1
|
||||
- hcloud_network.hcloud_network_info[0].subnetworks | list | count == 1
|
||||
- hcloud_network.hcloud_network_info[0].routes | list | count == 1
|
||||
- hcloud_network.hcloud_network_info | selectattr('name','equalto','{{ hcloud_network_name }}') | list | count >= 1
|
||||
- hcloud_network.hcloud_network_info[0].subnetworks | list | count >= 1
|
||||
- hcloud_network.hcloud_network_info[0].routes | list | count >= 1
|
||||
|
||||
- name: test gather hcloud network info with correct label selector
|
||||
hcloud_network_info:
|
||||
|
|
Loading…
Reference in a new issue