diff options
Diffstat (limited to 'test/integration/targets/cs_securitygroup/tasks/main.yml')
-rw-r--r-- | test/integration/targets/cs_securitygroup/tasks/main.yml | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/test/integration/targets/cs_securitygroup/tasks/main.yml b/test/integration/targets/cs_securitygroup/tasks/main.yml index de62ba150f..ef61f1fbb3 100644 --- a/test/integration/targets/cs_securitygroup/tasks/main.yml +++ b/test/integration/targets/cs_securitygroup/tasks/main.yml @@ -17,6 +17,16 @@ - sg|failed - "sg.msg == 'missing required arguments: name'" +- name: test present security group in check mode + cs_securitygroup: name={{ cs_resource_prefix }}_sg + register: sg + check_mode: true +- name: verify results of create security group in check mode + assert: + that: + - sg|success + - sg|changed + - name: test present security group cs_securitygroup: name={{ cs_resource_prefix }}_sg register: sg @@ -37,6 +47,17 @@ - not sg|changed - sg.name == "{{ cs_resource_prefix }}_sg" +- name: test absent security group in check mode + cs_securitygroup: name={{ cs_resource_prefix }}_sg state=absent + register: sg + check_mode: true +- name: verify results of absent security group in check mode + assert: + that: + - sg|success + - sg|changed + - sg.name == "{{ cs_resource_prefix }}_sg" + - name: test absent security group cs_securitygroup: name={{ cs_resource_prefix }}_sg state=absent register: sg |