13 AFSROOT
=${AFSROOT-/afs}
54 strange-characters-c \
55 strange-other-characters \
83 getdents-and-unlink1 \
84 getdents-and-unlink2 \
85 getdents-and-unlink3 \
90 find-and-cat-openbsd \
91 test-gunzip-gnu-mirror \
95 copy-and-diff-gnu-mirror \
99 macos-getattrlist-leak \
104 # this should really be work, but it's hard and it doesn't work so
105 # leave it out not to scare users
121 # you need to be root to run this: setgroups
127 many-files-with-content \
137 linebreak
=":-------------------------------;"
144 usage
="Usage: $0 [-user user] [-arla|-milko] [-all] [-fast] [-fail] [-large] [-j] [-verbose] [-x] tests ..."
153 -verbose) VERBOSE
=yes;;
154 -user) RUNAS
=$2; shift;;
155 -x) SHELLVERBOSE
="-x";;
156 -p) PRINT_CACHESIZE
="yes";;
157 -arla) TESTS
="$ARLA_TESTS";TEST_MODE
="arla";;
158 -milko) TESTS
="$MILKO_TESTS";TEST_MODE
="milko";;
159 -help|
--help) echo $usage;
160 echo "arla tests available: $linebreak"; for a
in "$ARLA_TESTS"; do echo $a ; done;
161 echo "milko tests available: $linebreak"; for a
in "$MILKO_TESTS"; do echo $a ; done;
163 -version|
--version) echo "$0 $Id$"; exit 0;;
164 -*) echo "$0: Bad option $1"; echo $usage; exit 1;;
170 if test "X$WORKDIR" = "X";then
171 echo "WORKDIR=workdir $0 $* or env WORKDIR=workdir $0 $*"; exit 1;
175 if test "X$ALL" != "X" ; then
177 elif test $# -lt 1; then
183 # these are variables exported to the scripts
190 # and file descriptors
195 if test "$VERBOSE" = "yes"; then
203 # Find out where we really are
205 srcdir
=`cd $srcdir; pwd`
206 objdir
=`cd $objdir; pwd`
211 echo "-------------------------------------------------"
212 echo "$PACKAGE-$VERSION"
213 echo "hosttype $host"
214 echo "${SHELL},${SHELLVERBOSE},${VERBOSE},${PARALLELL},${FAST}"
215 echo "testmode ${TEST_MODE}"
216 echo "runas ${RUNAS}"
221 echo "-------------------------------------------------"
223 test "X$VERBOSE" != "X" && echo "Running tests"
228 if [ X
$h = X
] ; then
232 for a
in $RUNTESTS; do
234 # XXX Test if binary in $srcdir, shellscript in $srcdir else
235 # its a binary in objdir
237 if test -x ${srcdir}/$a ; then
239 elif test -f ${srcdir}/$a ; then
240 b
="${SHELL} ${SHELLVERBOSE} ${srcdir}/$a"
244 echo "`date '+%Y-%m-%d %H:%M:%S'` - Running $a"
245 test "X$VERBOSE" != "X" && echo "Running test $a ($b)."
246 b
="${objdir}/asu $RUNAS $b"
247 tmpdir
="$h-$a-`date +%Y-%m-%d-%H-%M-%S`-$$"
248 cd $WORKDIR && mkdir
$tmpdir && (cd $tmpdir && $b ${PARALLELL})
250 test "X$VERBOSE" != "X" && echo "Saved res = $saved_res"
251 if test "X${PARALLELL}" = "X" ;then
252 if test $saved_res != 0 ; then
253 echo "Test $a FAILED"
254 FAILEDTESTS
="${FAILEDTESTS} $a";
256 if test X
$FAIL != X
; then break; fi
258 test "X$VERBOSE" != "X" && echo "Test $a succeeded, tmpdir is removed"
259 ${objdir}/rm-rf
$tmpdir
261 test "X$VERBOSE" != "X" && echo "Done test $a."
263 test "X${PRINT_CACHESIZE}" = Xyes
&& $objdir/..
/appl
/fs
/fs calculate
269 if test "$FAILEDTESTS"; then
270 echo "-----------------------------------------------------------"
271 echo "Failed test(s) were: $FAILEDTESTS"
273 echo "All test(s) were succesful!"