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
|
#!/bin/sh
#$Id: run-misc,v 1.2 2006/01/04 14:48:13 rockyb Exp $
if test -z "$srcdir" ; then
srcdir=`pwd`
fi
if test -z "$builddir" ; then
builddir=`pwd`
fi
. ${builddir}/check_common
TOP_BUILDDIR=`pwd`/../
export TOP_BUILDDIR
TEST_NAME='misc'
TEST_FILE="/tmp/${TEST_NAME}.check"
TEST_FILTERED_FILE="/tmp/${TEST_NAME}-filtered.check"
OUT1_NAME='misc-output'
OUT1_FILE="/tmp/${OUT1_NAME}.check"
rm -f $OUT1_FILE
(cd $srcdir && ${THIS_SH} ${TEST_NAME}.tests > $TEST_FILE 2>&1 < /dev/null)
# Different OS's handle ARGV differently, and "info args" may come out
# differently depending on that.
cat ${TEST_FILE} | sed -e "s:1 = ./dbg-test2.sh:1 = dbg-test2.sh:" >${TEST_FILTERED_FILE}
check_output $TEST_FILTERED_FILE ${srcdir}/${TEST_NAME}.right
rc=$?
if test $rc -eq 0 ; then
exit $rc
fi
check_output $OUT1_FILE ${srcdir}/${OUT1_NAME}.right
# Return code tells testing mechanism whether passed or not.
exit $?
#;;; Local Variables: ***
#;;; mode:shell-script ***
#;;; eval: (sh-set-shell "bash") ***
#;;; End: ***
|