Collect output from coverage job
Add a post-run playbook to tox-cover job to collect the coverage report detail and copy it to the log root of the executor. Change-Id: Ibad091f7630832eb993133b0f43a60931b3dfd75
This commit is contained in:
parent
ecd0d55ce1
commit
74a40ec89e
3
playbooks/tox/cover-post.yaml
Normal file
3
playbooks/tox/cover-post.yaml
Normal file
@ -0,0 +1,3 @@
|
||||
- hosts: all
|
||||
roles:
|
||||
- role: fetch-coverage-output
|
20
roles/fetch-coverage-output/README.rst
Normal file
20
roles/fetch-coverage-output/README.rst
Normal file
@ -0,0 +1,20 @@
|
||||
Collect output from a coverage run
|
||||
|
||||
By default, this copies the output from a coverage run
|
||||
on the worker to the log root of the executor.
|
||||
|
||||
**Role Variables**
|
||||
|
||||
.. zuul:rolevar:: zuul_executor_dest
|
||||
:default: {{ zuul.executor.log_root }}
|
||||
|
||||
The destination directory on the executor. By default, the log
|
||||
root.
|
||||
|
||||
.. zuul:rolevar:: coverage_output_src
|
||||
:default: {{ zuul.project.canonical_name }}/cover/
|
||||
|
||||
The location on the worker from which to fetch the coverage
|
||||
output detail. By default, the ``cover`` dir of the current
|
||||
project.
|
||||
|
2
roles/fetch-coverage-output/defaults/main.yaml
Normal file
2
roles/fetch-coverage-output/defaults/main.yaml
Normal file
@ -0,0 +1,2 @@
|
||||
zuul_executor_dest: "{{ zuul.executor.log_root }}"
|
||||
coverage_output_src: "src/{{ zuul.project.canonical_name }}/cover/"
|
6
roles/fetch-coverage-output/tasks/main.yaml
Normal file
6
roles/fetch-coverage-output/tasks/main.yaml
Normal file
@ -0,0 +1,6 @@
|
||||
- name: Collect coverage details output
|
||||
synchronize:
|
||||
dest: "{{ zuul_executor_dest }}"
|
||||
mode: pull
|
||||
src: "{{ coverage_output_src }}"
|
||||
verify_host: true
|
Loading…
Reference in New Issue
Block a user