s3: fix make test with external libtalloc or libtdb.
authorMichael Adam <obnox@samba.org>
Fri, 19 Jun 2009 19:04:06 +0000 (21:04 +0200)
committerMichael Adam <obnox@samba.org>
Fri, 19 Jun 2009 19:13:38 +0000 (21:13 +0200)
This skips the talloctort and tdbtorture tests when the
corresponding binaries are not present.
There might be more clever ways of detecting wether samba
has been linked with internal or external libraries, but
as a first approximation, this seems valid.

Michael

source3/script/tests/test_local_s3.sh

index 1840779085307cd09b65abb1fe50d3389eda3bca..0c94871ba5ea721a392b892b4a7b9f2b783923f3 100755 (executable)
@@ -16,14 +16,23 @@ incdir=`dirname $0`
 
 failed=0
 
-testit "talloctort" $VALGRIND $BINDIR/talloctort || \
-    failed=`expr $failed + 1`
+
+if test -x bin/talloctort ; then
+       testit "talloctort" $VALGRIND $BINDIR/talloctort || \
+               failed=`expr $failed + 1`
+else
+       echo "Skipping talloctort"
+fi
 
 testit "replacetort" $VALGRIND $BINDIR/replacetort || \
     failed=`expr $failed + 1`
 
-testit "tdbtorture" $VALGRIND $BINDIR/tdbtorture || \
-    failed=`expr $failed + 1`
+if test -x bin/tdbtorture ; then
+       testit "tdbtorture" $VALGRIND $BINDIR/tdbtorture || \
+               failed=`expr $failed + 1`
+else
+       echo "Skipping tdbtorture"
+fi
 
 testit "smbconftort" $VALGRIND $BINDIR/smbconftort $CONFIGURATION || \
        failed=`expr $failed + 1`