author | Alberto Bertogli
<albertito@blitiri.com.ar> 2011-02-23 00:43:43 UTC |
committer | Alberto Bertogli
<albertito@blitiri.com.ar> 2011-02-23 00:43:43 UTC |
parent | 96b8cd2804340006487c5b913b78acf688b69201 |
tests/util/quick-test-run.sh | +11 | -3 |
diff --git a/tests/util/quick-test-run.sh b/tests/util/quick-test-run.sh index 0427db2..54aa4af 100755 --- a/tests/util/quick-test-run.sh +++ b/tests/util/quick-test-run.sh @@ -24,6 +24,14 @@ fi set -e +function get_tmp() { + if which tempfile > /dev/null 2> /dev/null; then + tempfile -p libjio-tests + else + echo ${TMPDIR:-/tmp}/libjio-tests-$$.tmp + fi +} + case "$1" in normal) echo "behaviour tests (normal)" @@ -31,7 +39,7 @@ case "$1" in echo echo "stress tests (normal)" ./wrap-python 3 ../stress/jiostress \ - $(tempfile -p libjio-tests) 20 -n 50 -p 3 + $(get_tmp -p libjio-tests) 20 -n 50 -p 3 ;; fiu) echo "behaviour tests (all)" @@ -39,11 +47,11 @@ case "$1" in echo echo "stress tests (normal)" ./wrap-python 3 ../stress/jiostress \ - $(tempfile -p libjio-tests) 20 -n 50 -p 3 + $(get_tmp -p libjio-tests) 20 -n 50 -p 3 echo echo "stress tests (fiu)" ./wrap-python 3 ../stress/jiostress \ - $(tempfile -p libjio-tests) 20 -n 400 --fi + $(get_tmp -p libjio-tests) 20 -n 400 --fi ;; esac