Skip to content

Commit 2ff95a1

Browse files
committed
Fix expectedFailuresList incorrect overwrite
During a job run, we have noticed that the job status was reported as success despite an error occurring. The root cause was that stestr faling list was empty due to an error arising before any tests were executed. However, expectedFailuresList mistakenly interpreted this as if there were no failing tests. This patch aims to fix this edge case.
1 parent f31c3c8 commit 2ff95a1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

container-images/tcib/base/os/tempest/run_tempest.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -482,7 +482,7 @@ if [ ${TEMPEST_DEBUG_MODE} == true ]; then
482482
sleep infinity
483483
fi
484484

485-
if [ ! -z ${TEMPEST_EXPECTED_FAILURES_LIST} ]; then
485+
if [ -s ${TEMPEST_LOGS_DIR}stestr_failing.txt ] && [ -s ${TEMPEST_EXPECTED_FAILURES_LIST} ]; then
486486
echo "Failing tests marked as expected failures"
487487
grep -Fxf ${TEMPEST_EXPECTED_FAILURES_LIST} ${TEMPEST_LOGS_DIR}stestr_failing.txt
488488
if ! grep -Fxv -q -f ${TEMPEST_EXPECTED_FAILURES_LIST} ${TEMPEST_LOGS_DIR}stestr_failing.txt ; then

0 commit comments

Comments
 (0)