regtests.sh 438 Bytes
Newer Older
1 2 3
#!/bin/sh
# regression tests for why3

4 5
TMP=$PWD/why3regtests.out

6
cd `dirname $0`
7

MARCHE Claude's avatar
MARCHE Claude committed
8
res=0
9 10

run_dir () {
11 12 13
    for f in `ls $1/*/why3session.xml`; do
        d=`dirname $f`
	echo -n "Replaying "$d"... "
MARCHE Claude's avatar
MARCHE Claude committed
14
	if ! ../bin/why3replayer $d 2>/dev/null > $TMP ; then
15 16
	    echo "FAILED:"
	    cat $TMP
MARCHE Claude's avatar
MARCHE Claude committed
17
	    res=1
18 19 20 21 22 23 24
	else
	    echo "OK"
	fi
    done
}

echo "=== Logic ==="
25
run_dir .
26 27
echo ""

28 29
echo "=== Programs ==="
run_dir programs
30 31
echo ""

MARCHE Claude's avatar
MARCHE Claude committed
32 33
exit $res

34