Fix travis-job script to not fail when all tests succeed

Fixed by calling the "showdiag" function only when external tests fail.
This commit is contained in:
Daniel Thayer 2018-06-26 08:30:49 -05:00
parent a33d2d13bf
commit f57611c2f0

View file

@ -158,8 +158,7 @@ run() {
echo echo
echo "Running external tests ##############################################" echo "Running external tests ##############################################"
echo echo
trap showdiag EXIT make || showdiag
make
# If we get here, then external tests were successful. # If we get here, then external tests were successful.
exit $ret exit $ret
@ -175,6 +174,8 @@ showdiag() {
echo "Output of failed external tests #####################################" && \ echo "Output of failed external tests #####################################" && \
echo && \ echo && \
grep -v "... not available, skipped" $f grep -v "... not available, skipped" $f
exit 1
} }
if [ "$step" != "install" ] && [ "$step" != "build" ] && [ "$step" != "run" ]; then if [ "$step" != "install" ] && [ "$step" != "build" ] && [ "$step" != "run" ]; then