2007-02-05 20:15:03 +02:00
|
|
|
#!/bin/sh
|
|
|
|
|
2007-07-10 23:49:05 +03:00
|
|
|
LC_ALL=C
|
|
|
|
export LC_ALL
|
|
|
|
|
2010-03-02 23:59:16 +02:00
|
|
|
src_path=$1
|
2008-11-23 14:36:44 +02:00
|
|
|
target_exec=$2
|
|
|
|
target_path=$3
|
|
|
|
|
2010-03-02 23:59:27 +02:00
|
|
|
[ "${V-0}" -gt 0 ] && echov=echo || echov=:
|
|
|
|
[ "${V-0}" -gt 1 ] || exec 2>/dev/null
|
|
|
|
|
2010-03-02 23:59:16 +02:00
|
|
|
refdir="$src_path/tests/ref/seek"
|
2007-06-08 01:36:39 +03:00
|
|
|
datadir="tests/data"
|
2007-02-05 20:15:03 +02:00
|
|
|
|
2010-03-02 23:59:16 +02:00
|
|
|
list=$(ls -1 $datadir/vsynth2/* $datadir/acodec/*)
|
|
|
|
err=0
|
2007-02-05 20:15:03 +02:00
|
|
|
|
|
|
|
for i in $list ; do
|
2010-03-02 23:59:16 +02:00
|
|
|
base=$(basename $i)
|
|
|
|
logfile="$datadir/$base.seek.regression"
|
|
|
|
reffile="$refdir/$base.ref"
|
2010-03-02 23:59:27 +02:00
|
|
|
echo "TEST SEEK $base"
|
|
|
|
$echov $target_exec $target_path/tests/seek_test $target_path/$i
|
2010-03-02 23:59:16 +02:00
|
|
|
$target_exec $target_path/tests/seek_test $target_path/$i > $logfile
|
|
|
|
diff -u -w "$reffile" "$logfile" || err=1
|
2007-02-05 20:15:03 +02:00
|
|
|
done
|
|
|
|
|
2010-03-02 23:59:16 +02:00
|
|
|
if [ $err = 0 ]; then
|
2007-02-05 20:15:03 +02:00
|
|
|
echo
|
2008-01-30 01:30:00 +02:00
|
|
|
echo seek regression test: success
|
2007-02-05 20:15:03 +02:00
|
|
|
exit 0
|
|
|
|
else
|
|
|
|
echo
|
2008-01-30 01:30:00 +02:00
|
|
|
echo seek regression test: error
|
2007-02-05 20:15:03 +02:00
|
|
|
exit 1
|
|
|
|
fi
|