blob: 96150da889bff4aefecc787748a4509108fad92c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
#! /bin/sh
# Driver for sanity checks
set -e
dirs="[0-9]*"
failures=""
full=n
for opt; do
case "$opt" in
-k | --keep-going) full=y ;;
--list-tests) echo $dirs; exit 0;;
*) echo "Unknown option $opt"
exit 2
;;
esac
done
singlerun() {
echo ""
echo "sanity $1:"
cd $1
if ! ./testsuite.sh; then
echo "#################################################################"
echo "######### FAILURE: $1"
echo "#################################################################"
if [ $2 = "y" ]; then
failures="$failures $1"
else
exit 1;
fi
fi
cd ..
}
for i in $dirs; do singlerun $i $full; done
if [ x"$failures" = x"" ]; then
echo "sanity tests are successful" && exit 0
else
echo "sanity test failed ($failures)" && exit 1
fi
|