Change tests to not show failure reasons in build script

This commit is contained in:
Ethan P 2019-09-26 15:57:17 -07:00
parent 8adaae9f2c
commit 3e399294e2
No known key found for this signature in database
GPG Key ID: 6963FD04F6CF35EA
2 changed files with 9 additions and 5 deletions

View File

@ -264,7 +264,7 @@ done
if "$OPT_VERIFY"; then if "$OPT_VERIFY"; then
printc "\n%{YELLOW}Verifying scripts...%{CLEAR}\n" 1>&2 printc "\n%{YELLOW}Verifying scripts...%{CLEAR}\n" 1>&2
"$HERE/test/run.sh" consistency-test TEST_QUIET=true "$HERE/test/run.sh" consistency-test
exit $? exit $?
fi fi

View File

@ -25,14 +25,18 @@ fail() {
c="in source script" c="in source script"
fi fi
printf "\x1B[33mError (%s):\x1B[0m\n" "$c" if [[ "$TEST_QUIET" != "true" ]]; then
bat --style=numbers --paging=never - printf "\x1B[33mError (%s):\x1B[0m\n" "$c"
bat --style=numbers --paging=never -
fi
;; ;;
DIFF) DIFF)
printf "\x1B[33m%s\x1B[0m\n" "$2" printf "\x1B[33m%s\x1B[0m\n" "$2"
printf "\x1B[33mDifference:\x1B[0m\n" if [[ "$TEST_QUIET" != "true" ]]; then
bat --style=plain --paging=never -l diff - printf "\x1B[33mDifference:\x1B[0m\n"
bat --style=plain --paging=never -l diff -
fi
;; ;;
esac esac
exit 1 exit 1