Collect testrepository.subunit.gz for translations

The show up in openstack-health, we need to publish the subunit file.
The file is written by the subunit files, so only publish it.

Change-Id: Ia2a4060c7e6ae3a5f9b8a8e8540c1d2c331850b1
This commit is contained in:
Andreas Jaeger 2017-11-25 18:52:34 +01:00
parent 0360aea196
commit ca7a4f4ff4
5 changed files with 32 additions and 0 deletions

View File

@ -9,3 +9,7 @@
command: "{{ ansible_user_dir }}/scripts/propose_translation_update.sh {{ zuul.project.short_name }} {{ zuul.branch }} {{ zuul.job }}"
args:
chdir: "src/{{ zuul.project.canonical_name }}"
- hosts: all
roles:
- fetch-translations-stestr-output

View File

@ -13,3 +13,4 @@
- hosts: all
roles:
- fetch-translation-output
- fetch-translations-stestr-output

View File

@ -0,0 +1,12 @@
Collect stestr output from translation jobs
This role collects only the testrepository.subunit file which has to
be compressed already.
**Role Variables**
.. zuul:rolevar:: zuul_work_dir
:default: {{ zuul.project.src_dir }}
Directory where ``testrepository.subunit.gz`` file is.

View File

@ -0,0 +1,2 @@
---
zuul_work_dir: "src/{{ zuul.project.canonical_name }}"

View File

@ -0,0 +1,13 @@
- name: Register testrepository.subunit file
stat:
path: "{{ zuul_work_dir }}/testrepository.subunit.gz"
register: subunit
- name: Collect test-results
synchronize:
dest: "{{ zuul.executor.log_root }}"
mode: pull
src: "{{ zuul_work_dir }}/testrepository.subunit.gz"
verify_host: true
when:
- subunit.stat.exists