Use fetch-subunit-output role
Currently there is a zuul-jobs role only used in this tempest job while
other jobs mostly use fetch-subunit-output role.
This changes tries to consolidate towards the most used role, to be able
to clean up zuul-jobs a bit.
Change-Id: I404760ba34767660f8816f48712e13dccad67440
Depends-On: https://review.openstack.org/548406
diff --git a/roles/process-stackviz/README.rst b/roles/process-stackviz/README.rst
index 54c217b..a8447d2 100644
--- a/roles/process-stackviz/README.rst
+++ b/roles/process-stackviz/README.rst
@@ -16,7 +16,7 @@
The stage directory where the input data can be found and
the output will be produced.
-.. zuul:rolevar:: test_results_stage_name
- :default: test_results
+.. zuul:rolevar:: zuul_work_dir
+ :default: {{ devstack_base_dir }}/tempest
- The name of the subunit file to be used as input.
+ Directory to work in. It has to be a fully qualified path.
diff --git a/roles/process-stackviz/defaults/main.yaml b/roles/process-stackviz/defaults/main.yaml
index c6a64d1..f3bc32b 100644
--- a/roles/process-stackviz/defaults/main.yaml
+++ b/roles/process-stackviz/defaults/main.yaml
@@ -1,3 +1,3 @@
devstack_base_dir: /opt/stack
stage_dir: "{{ ansible_user_dir }}"
-test_results_stage_name: test_results
+zuul_work_dir: "{{ devstack_base_dir }}/tempest"
diff --git a/roles/process-stackviz/tasks/main.yaml b/roles/process-stackviz/tasks/main.yaml
index 09de606..82f8f3d 100644
--- a/roles/process-stackviz/tasks/main.yaml
+++ b/roles/process-stackviz/tasks/main.yaml
@@ -9,11 +9,11 @@
- name: Check if subunit data exists
stat:
- path: "{{ stage_dir }}/{{ test_results_stage_name }}.subunit"
+ path: "{{ zuul_work_dir }}/testrepository.subunit"
register: subunit_input
- debug:
- msg: "Subunit file could not be found at {{ stage_dir }}/{{ test_results_stage_name }}.subunit"
+ msg: "Subunit file could not be found at {{ zuul_work_dir }}/testrepository.subunit"
when: not subunit_input.stat.exists
- name: Install stackviz