tests: Ensure failure if beakerlib results file not found

In example here
https://209.132.184.41:8493/logs/pull-887-20191025-100505-509b9eae-weldr-lorax--fedora-31-tar/log.html

we're seeing stuff like:
/tests/test_cli.sh: line 109: /tmp/composer-test.wIAITH/TestResults: No such file or directory

but the result is PASS
This commit is contained in:
Alexander Todorov 2019-10-25 14:04:32 +03:00 committed by Alexander Todorov
parent c43ba9e78f
commit 2b578dcee8

View File

@ -37,6 +37,9 @@ run_beakerlib_tests() {
}
parse_beakerlib_results() {
if [ ! -f "$BEAKERLIB_DIR/TestResults" ]; then
exit "$BEAKERLIB_DIR/TestResults not found" 1
fi
. $BEAKERLIB_DIR/TestResults
TESTRESULT_RESULT_ECODE="${TESTRESULT_RESULT_ECODE:-}"