From 472ec21a9163c81cee9ad73e189c58a60d943a11 Mon Sep 17 00:00:00 2001 From: Arx Cruz Date: Tue, 8 Jun 2021 11:42:31 +0200 Subject: [PATCH] Generate list of failing tests Add a file containing the list of failing tests is important to send these to logstash and make it easy for people identify how often a particular test is failing in a particular job. This should not impact the time of the job or the size of the file, once it's a small and very quickly command to run Change-Id: Ib6c2dfc41ac48c3ca6822d6298e1cc55f5c28fbe --- tasks/tempest_run.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/tasks/tempest_run.yml b/tasks/tempest_run.yml index fb940e80..dbf0c8bd 100644 --- a/tasks/tempest_run.yml +++ b/tasks/tempest_run.yml @@ -142,6 +142,24 @@ - skip_ansible_lint when: tempest_run_stackviz | bool + - name: Create tempest failing tests file + shell: | + set -e + if [ -d {{ tempest_venv_bin }} ]; + then + . {{ tempest_venv_bin }}/activate + fi + {{ stestr_executable }} failing --list > {{ tempest_log_dir }}/failing_tests.log + args: + chdir: "{{ tempest_workspace }}" + executable: /bin/bash + failed_when: false + changed_when: false + tags: + # don't trigger ANSIBLE0013 + - skip_ansible_lint + when: tempest_tests_run.rc != 0 + - name: Fail if tempest tests did not succeed assert: that: