tests/run.sh: Print special message for timeout
The timeout utility guarantees an exit code of 124 when the process died due to timeout. Since awesome only ever exits with 0 or 1, we can use this to reliably detect timeouts and print a matching message. Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
parent
60ee10cfff
commit
a430ac1e23
|
@ -217,7 +217,11 @@ for f in $tests; do
|
|||
wait $awesome_pid
|
||||
code=$?
|
||||
set -e
|
||||
[ "$code" != 0 ] && echo "Awesome exited with status code $code"
|
||||
case $code in
|
||||
0) ;;
|
||||
124) echo "Awesome was killed due to timeout after $timeout_stale seconds" ;;
|
||||
*) echo "Awesome exited with status code $code" ;;
|
||||
esac
|
||||
|
||||
if ! grep -q -E '^Test finished successfully$' $awesome_log ||
|
||||
grep -q -E '[Ee]rror|assertion failed' $awesome_log; then
|
||||
|
|
Loading…
Reference in New Issue