diff options
author | Wainer dos Santos Moschetta <wainersm@redhat.com> | 2020-12-11 15:38:26 -0300 |
---|---|---|
committer | Thomas Huth <thuth@redhat.com> | 2020-12-18 12:25:42 +0100 |
commit | ba2232bae6d67706b6a72e487fd57ccf38486a14 (patch) | |
tree | 93e4f2a4f39ff5b60fc043f43c406212e234688d /.gitlab-ci.yml | |
parent | d44423ad14d0fd9d90b86f2b50f24c7993b22777 (diff) | |
download | qemu-ba2232bae6d67706b6a72e487fd57ccf38486a14.zip qemu-ba2232bae6d67706b6a72e487fd57ccf38486a14.tar.gz qemu-ba2232bae6d67706b6a72e487fd57ccf38486a14.tar.bz2 |
gitlab-ci: Refactor code that show logs of failed acceptances
Replace the code (python) on after_script of the acceptance jobs that
is currently used to show the logs of failed tests. Instead it is used
the Avocado's testlogs plug-in which works likewise.
Signed-off-by: Wainer dos Santos Moschetta <wainersm@redhat.com>
Reviewed-by: Willian Rampazzo <willianr@redhat.com>
Message-Id: <20201211183827.915232-3-wainersm@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r-- | .gitlab-ci.yml | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 98bff03..85aa20f 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -58,13 +58,14 @@ include: - echo "[datadir.paths]" > ~/.config/avocado/avocado.conf - echo "cache_dirs = ['${CI_PROJECT_DIR}/avocado-cache']" >> ~/.config/avocado/avocado.conf + - echo -e '[job.output.testlogs]\nstatuses = ["FAIL"]' + >> ~/.config/avocado/avocado.conf - if [ -d ${CI_PROJECT_DIR}/avocado-cache ]; then du -chs ${CI_PROJECT_DIR}/avocado-cache ; fi - export AVOCADO_ALLOW_UNTRUSTED_CODE=1 after_script: - cd build - - python3 -c 'import json; r = json.load(open("tests/results/latest/results.json")); [print(t["logfile"]) for t in r["tests"] if t["status"] not in ("PASS", "SKIP", "CANCEL")]' | xargs cat - du -chs ${CI_PROJECT_DIR}/avocado-cache build-system-ubuntu: |