./run: Increase default timeout from 1h -> 4h.

1 hour was not long enough for the C API tests when run in Koji.

This update commit caab9f1e6f.
This commit is contained in:
Richard W.M. Jones
2013-07-11 21:05:56 +01:00
parent ae78381287
commit a7b9d61cde

10
run.in
View File

@@ -222,11 +222,15 @@ fi
# - print how long it takes to run the test
# - timeout if the test takes too long to run
# Originally 1h, but that is not long enough to run the C API
# tests on Koji.
timeout_period=4h
# Do we have Padraig's timeout utility (from coreutils)?
if timeout --help >/dev/null 2>&1; then
# Timeout (SIGTERM) after 1 hour.
# Timeout (SIGTERM) after $timeout_period.
# Then send a second SIGKILL 30 seconds later.
timeout="timeout -k 30s 1h"
timeout="timeout -k 30s $timeout_period"
fi
pid=$$
@@ -246,7 +250,7 @@ elif [ "$fail" -eq 124 ]; then
# Timed out.
echo "$b/run --test" "$@"
cat $tmpout
echo "$b/run: command timed out after 1 hour"
echo "$b/run: command timed out after $timeout_period"
else
# Test failed.
echo "$b/run --test" "$@"