test.sh: write errors to stdout
stdout is swallowed by the result verification
This commit is contained in:
parent
ebf0723b48
commit
f477ec985d
1 changed files with 2 additions and 2 deletions
4
test.sh
4
test.sh
|
@ -7,7 +7,7 @@ cd "$(dirname "${BASH_SOURCE[0]}")"
|
||||||
run_solution() {
|
run_solution() {
|
||||||
if [ -d "$solution" ]; then
|
if [ -d "$solution" ]; then
|
||||||
runfile=$solution/run.sh
|
runfile=$solution/run.sh
|
||||||
[ -f "$runfile" ] || { echo "Error: $runfile not found"; exit 1; }
|
[ -f "$runfile" ] || { echo "Error: $runfile not found" >&2; exit 1; }
|
||||||
"$runfile" "$input"
|
"$runfile" "$input"
|
||||||
else
|
else
|
||||||
case "$(basename "$solution")" in
|
case "$(basename "$solution")" in
|
||||||
|
@ -18,7 +18,7 @@ run_solution() {
|
||||||
python "$solution" < "$input"
|
python "$solution" < "$input"
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
echo "Error: Unknown solution type: $solution"
|
echo "Error: Unknown solution type: $solution" >&2
|
||||||
exit 1
|
exit 1
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
Loading…
Reference in a new issue