7 rm -f test.failed test.success test.ignored
9 if [ xvalgrind = "x$1" ] ; then
10 valgrind="libtool --mode=execute valgrind --show-reachable=yes"
14 for test in xbt/log_usage@EXEEXT@ \
15 xbt/dynar_int@EXEEXT@ xbt/dynar_double@EXEEXT@ xbt/dynar_string@EXEEXT@ \
16 xbt/dict_usage@EXEEXT@ xbt/dict_crash@EXEEXT@ \
17 xbt/config_usage@EXEEXT@ \
18 xbt/heap_bench@EXEEXT@ \
20 gras/trp_tcp_usage@EXEEXT@ gras/trp_file_usage@EXEEXT@ \
21 gras/datadesc_usage@EXEEXT@ \
22 "gras/datadesc_usage@EXEEXT@ --read @top_srcdir@/../testsuite/gras/datadesc.little32" \
23 "gras/datadesc_usage@EXEEXT@ --read @top_srcdir@/../testsuite/gras/datadesc.little64" \
24 "gras/datadesc_usage@EXEEXT@ --read @top_srcdir@/../testsuite/gras/datadesc.big32" \
25 "gras/datadesc_usage@EXEEXT@ --read @top_srcdir@/../testsuite/gras/datadesc.big64" \
26 "gras/datadesc_usage@EXEEXT@ --read @top_srcdir@/../testsuite/gras/datadesc.aix" \
28 surf/maxmin_usage@EXEEXT@ surf/maxmin_bench@EXEEXT@ \
29 surf/trace_usage@EXEEXT@ \
30 surf/surf_usage@EXEEXT@
32 tests_nb=`expr $tests_nb + 1`
33 echo "#### Test $test"
34 dir=`echo $test |sed 's|\([^/]*\)/\(.*\)|\1|'`
35 cmd=`echo $test |sed 's|\([^/]*\)/\(.*\)|\2|'`
36 if [ x@EXEEXT@ = x ] ; then
41 if [ "x$test" = "xdict_crash" ] ; then
43 $wine ./$cmd --gras-log="root.thres=info" 2>&1
48 # if the user defines walgrind while cross-compiling, too bad
49 $wine $valgrind ./$cmd --gras-log="root.thres=info" 2>&1
53 if [ $retval != 0 ] ; then if [ $retval != 77 ]; then
54 echo "## failed. Rerun $test with full details."
55 if [ "x$test" = "xdict_crash" ] ; then
57 $wine ./$cmd --gras-log="root.thres=debug" 2>&1
61 $wine $valgrind ./$cmd --gras-log="root.thres=debug" 2>&1
64 failed_nb=`expr $failed_nb + 1`
65 echo " $test (returned $retval)" >> test.failed
67 echo "## Ignored since it returned 77"
68 ignored_nb=`expr $ignored_nb + 1`
69 echo " $test" >> test.ignored
72 success_nb=`expr $success_nb + 1`
73 echo " $test" >> test.success
80 echo "$success_nb tests of $tests_nb successfull:"
83 if [ $ignored_nb != 0 ] ; then
84 echo "$failed_nb tests of $tests_nb ignored:"
86 echo " (they returned 77, meaning that they are not applicable)"
88 if [ $failed_nb != 0 ] ; then
89 echo "$failed_nb tests of $tests_nb failed: "
91 echo "Rerun the tests using the following command: script -c 'make test' gras.tests.log"
92 echo " and send the following informations to martin.quinson@ens-lyon.fr:"
93 echo " - the file gras.tests.log produced by this command."
94 echo " - a short description of the target platform (arch, OS, distrib, compiler)."
95 echo " - the config.log produced by the compilation."
98 rm -f test.success test.failed test.ignored