pytest script return status is not a reliable indicator for success/failure
This commit is contained in:
parent
f57a3b2a0b
commit
8892e2e426
1 changed files with 6 additions and 1 deletions
|
@ -29,7 +29,12 @@ run_tests() {
|
||||||
echo "Running tests"
|
echo "Running tests"
|
||||||
cd "$REPO_DIR"
|
cd "$REPO_DIR"
|
||||||
pytest 2>&1 | tee "$TEST_LOG"
|
pytest 2>&1 | tee "$TEST_LOG"
|
||||||
return $?
|
grep -e '^FAILED ' "$TEST_LOG"
|
||||||
|
if [[ $? == 0 ]]; then
|
||||||
|
return 2 # FAILURE
|
||||||
|
fi
|
||||||
|
|
||||||
|
return 0 # PASSED
|
||||||
}
|
}
|
||||||
|
|
||||||
########
|
########
|
||||||
|
|
Loading…
Reference in a new issue