Skip to content

Commit

Permalink
check-exercises: Move echo before test-exercise (#447)
Browse files Browse the repository at this point in the history
Notice that below `test-exercise` there is a check of `$?`. This means
nothing should come after `test-exercise`.

If we fail to do this, warnings will never cause the build to fail (as
we would like them to), because the `$?` is examining the exit code of
`echo`.

We need to move the `echo` (progress dot) that we added in
#446
a3a7b16
  • Loading branch information
petertseng authored Mar 5, 2018
1 parent dbffe82 commit ac8f5c6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions _test/check-exercises.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,15 @@ for exercise in $files; do
fi

if [ -n "$DENYWARNINGS" ]; then
# Output a progress dot; otherwise Travis may assume we're hung,
# if we don't produce output in > 10 mins.
echo -n '.'
# No-run mode so we see no test output.
# Quiet mode so we see no compile output
# (such as "Compiling"/"Downloading").
# Compiler errors will still be shown though.
# Both flags are necessary to keep things quiet.
./bin/test-exercise $directory --quiet --no-run
# Output a progress dot; otherwise Travis may assume we're hung,
# if we don't produce output in > 10 mins.
echo -n '.'
return_code=$(($return_code | $?))
else
# Run the test and get the status
Expand Down

0 comments on commit ac8f5c6

Please sign in to comment.