Skip to content
Snippets Groups Projects
Unverified Commit 246593d7 authored by Rafael Guterres Jeffman's avatar Rafael Guterres Jeffman Committed by GitHub
Browse files

Merge pull request #336 from seocam/dnszone-tests-cleanup

Added cleanup to the end of dnszone tests
parents 675125ed d69eb94d
No related branches found
No related tags found
No related merge requests found
---
- name: Ensure zone is absent.
ipadnszone:
ipaadmin_password: SomeADMINpassword
name:
- testzone.local
- test1.testzone.local
- test2.testzone.local
- test3.testzone.local
- 2.0.192.in-addr.arpa.
- 0.0.0.0.0.0.0.0.0.0.0.0.0.0.d.f.ip6.arpa.
- 1.0.0.0.e.f.a.c.8.b.d.0.1.0.0.2.ip6.arpa.
state: absent
---
- name: Cleanup test environment.
include_tasks: env_cleanup.yml
---
- name: Cleanup test environment.
include_tasks: env_cleanup.yml
...@@ -7,11 +7,8 @@ ...@@ -7,11 +7,8 @@
tasks: tasks:
# Setup # Setup
- name: Ensure zone is absent. - name: Setup testing environment
ipadnszone: include_tasks: env_setup.yml
ipaadmin_password: SomeADMINpassword
name: testzone.local
state: absent
# Tests # Tests
- name: Ensure zone is present. - name: Ensure zone is present.
...@@ -186,3 +183,7 @@ ...@@ -186,3 +183,7 @@
state: absent state: absent
register: result register: result
failed_when: result.changed failed_when: result.changed
# Teardown
- name: Teardown testing environment
include_tasks: env_teardown.yml
...@@ -7,11 +7,8 @@ ...@@ -7,11 +7,8 @@
tasks: tasks:
# Setup # Setup
- name: Ensure zone is absent. - name: Setup testing environment
ipadnszone: include_tasks: env_setup.yml
ipaadmin_password: SomeADMINpassword
name: testzone.local
state: absent
# Tests # Tests
- name: Ensure zone is present. - name: Ensure zone is present.
...@@ -317,3 +314,7 @@ ...@@ -317,3 +314,7 @@
admin_email: admin2@example.com admin_email: admin2@example.com
register: result register: result
failed_when: result.changed failed_when: result.changed
# Teardown
- name: Teardown testing environment
include_tasks: env_teardown.yml
...@@ -7,17 +7,10 @@ ...@@ -7,17 +7,10 @@
tasks: tasks:
# Setup # Setup
- name: Ensure zone is absent. - name: Setup testing environment
ipadnszone: include_tasks: env_setup.yml
ipaadmin_password: SomeADMINpassword
name: "{{ item }}"
state: absent
with_items:
- 2.0.192.in-addr.arpa.
- 0.0.0.0.0.0.0.0.0.0.0.0.0.0.d.f.ip6.arpa.
- 1.0.0.0.e.f.a.c.8.b.d.0.1.0.0.2.ip6.arpa.
# tests # Tests
- name: Ensure zone exists for reverse IP. - name: Ensure zone exists for reverse IP.
ipadnszone: ipadnszone:
ipaadmin_password: SomeADMINpassword ipaadmin_password: SomeADMINpassword
...@@ -100,13 +93,6 @@ ...@@ -100,13 +93,6 @@
register: result register: result
failed_when: result.changed failed_when: result.changed
# Cleanup # Teardown
- name: Ensure zone is absent. - name: Teardown testing environment
ipadnszone: include_tasks: env_teardown.yml
ipaadmin_password: SomeADMINpassword
name: "{{ item }}"
state: absent
with_items:
- "{{ ipv6_zone.dnszone.name }}"
- "{{ ipv6_sec_zone.dnszone.name }}"
- "{{ ipv4_zone.dnszone.name }}"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment