diff --git a/tests/integration/targets/inventory_gce/playbooks/setup.yml b/tests/integration/targets/inventory_gce/playbooks/setup.yml index d26ce149..78fbf3cd 100644 --- a/tests/integration/targets/inventory_gce/playbooks/setup.yml +++ b/tests/integration/targets/inventory_gce/playbooks/setup.yml @@ -4,7 +4,7 @@ connection: local gather_facts: false vars_files: - - vars.yml + - ../vars.yml tasks: - name: SETUP | Create network google.cloud.gcp_compute_network: diff --git a/tests/integration/targets/inventory_gce/playbooks/teardown.yml b/tests/integration/targets/inventory_gce/playbooks/teardown.yml index b4e48041..44cf14c4 100644 --- a/tests/integration/targets/inventory_gce/playbooks/teardown.yml +++ b/tests/integration/targets/inventory_gce/playbooks/teardown.yml @@ -4,7 +4,7 @@ connection: local gather_facts: false vars_files: - - vars.yml + - ../vars.yml tasks: - name: TEARDOWN | Delete instance # noqa: ignore-errors google.cloud.gcp_compute_instance: diff --git a/tests/integration/targets/inventory_gce/playbooks/test.yml b/tests/integration/targets/inventory_gce/playbooks/test.yml index aaa539af..25feba39 100644 --- a/tests/integration/targets/inventory_gce/playbooks/test.yml +++ b/tests/integration/targets/inventory_gce/playbooks/test.yml @@ -4,7 +4,7 @@ connection: local gather_facts: false vars_files: - - vars.yml + - ../vars.yml tasks: - name: TEST | render inventory file ansible.builtin.copy: @@ -27,4 +27,4 @@ - name: TEST | run test case ansible.builtin.include_tasks: - file: "testcase_{{ testcase }}.yml" + file: "../testcase_{{ testcase }}.yml" diff --git a/tests/integration/targets/inventory_gce/runme.sh b/tests/integration/targets/inventory_gce/runme.sh index 4b56a3a1..175dab85 100755 --- a/tests/integration/targets/inventory_gce/runme.sh +++ b/tests/integration/targets/inventory_gce/runme.sh @@ -11,7 +11,7 @@ RC=0 # we want to run teardown regardless of playbook exit status, so catch the # exit code of ansible-playbook manually set +e -for ts in playbooks/testcase_*.yml; +for ts in testcase_*.yml; do testcase=$( basename "$ts" | sed -e 's/testcase_//' | sed -e 's/.yml//' ) ansible-playbook playbooks/test.yml "$@" --extra-vars "testcase=${testcase}" diff --git a/tests/integration/targets/inventory_gce/playbooks/testcase_basic.yml b/tests/integration/targets/inventory_gce/testcase_basic.yml similarity index 100% rename from tests/integration/targets/inventory_gce/playbooks/testcase_basic.yml rename to tests/integration/targets/inventory_gce/testcase_basic.yml diff --git a/tests/integration/targets/inventory_gce/playbooks/testcase_hostname.yml b/tests/integration/targets/inventory_gce/testcase_hostname.yml similarity index 100% rename from tests/integration/targets/inventory_gce/playbooks/testcase_hostname.yml rename to tests/integration/targets/inventory_gce/testcase_hostname.yml diff --git a/tests/integration/targets/inventory_gce/playbooks/vars.yml b/tests/integration/targets/inventory_gce/vars.yml similarity index 100% rename from tests/integration/targets/inventory_gce/playbooks/vars.yml rename to tests/integration/targets/inventory_gce/vars.yml