Skip to content

Commit

Permalink
tests now have a strict 1 minute time limit
Browse files Browse the repository at this point in the history
  • Loading branch information
SheetJSDev committed Apr 2, 2014
1 parent e891711 commit 5591611
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 4 additions & 1 deletion test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,12 @@
# test.sh clean # removes test logs
# test.sh all # runs all tests
# logs are dumped in *.tests

timeout() { perl -e 'alarm shift; exec @ARGV' "$@"; }

do_test() {
echo "# $1" >>"$2".tests
$3 "$1" >/dev/null 2>>"$2".tests
timeout 60 $3 "$1" >/dev/null 2>>"$2".tests
echo "- $? $1" >>"$2".tests
}

Expand All @@ -24,6 +26,7 @@ case "$1" in
;;
"all")
for i in *.xls *.xlsb *.xlsm *.xlsx *.xml; do
if [[ $(grep -qx "$i" tests.skip) -gt 0 ]]; then continue; fi
echo $i >&2
do_test "$i" core "j"
#do_test "$i" xlrd "python tests/xlrd.py"
Expand Down
1 change: 1 addition & 0 deletions tests.skip
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
calendar_stress_test.xlsb

0 comments on commit 5591611

Please sign in to comment.