summaryrefslogtreecommitdiffstats
path: root/ansible_collections/community/grafana/tests/integration/targets/grafana_datasource/tasks/elastic.yml
diff options
context:
space:
mode:
Diffstat (limited to 'ansible_collections/community/grafana/tests/integration/targets/grafana_datasource/tasks/elastic.yml')
-rw-r--r--ansible_collections/community/grafana/tests/integration/targets/grafana_datasource/tasks/elastic.yml26
1 files changed, 26 insertions, 0 deletions
diff --git a/ansible_collections/community/grafana/tests/integration/targets/grafana_datasource/tasks/elastic.yml b/ansible_collections/community/grafana/tests/integration/targets/grafana_datasource/tasks/elastic.yml
index ff05b93f5..be5873574 100644
--- a/ansible_collections/community/grafana/tests/integration/targets/grafana_datasource/tasks/elastic.yml
+++ b/ansible_collections/community/grafana/tests/integration/targets/grafana_datasource/tasks/elastic.yml
@@ -286,6 +286,32 @@
- result.datasource.secureJsonFields.secureTest == true
- result.diff.after.secureJsonData is defined
+- name: Delete elasticsearch legacy datasource
+ register: result
+ community.grafana.grafana_datasource:
+ name: datasource/elasticLegacy
+ grafana_url: "{{ grafana_url }}"
+ grafana_user: "{{ grafana_username }}"
+ grafana_password: "{{ grafana_password }}"
+ state: absent
+
+- ansible.builtin.assert:
+ that:
+ - result.changed
+
+- name: Delete elasticsearch legacy datasource (idempotency)
+ register: result
+ community.grafana.grafana_datasource:
+ name: datasource/elasticLegacy
+ grafana_url: "{{ grafana_url }}"
+ grafana_user: "{{ grafana_username }}"
+ grafana_password: "{{ grafana_password }}"
+ state: absent
+
+- ansible.builtin.assert:
+ that:
+ - not result.changed
+
- name: Delete elasticsearch datasource
register: result
community.grafana.grafana_datasource: