summaryrefslogtreecommitdiff
path: root/source4/script/tests/selftest.sh
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2005-06-10 15:32:16 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:17:55 -0500
commit67c606b86314ada34b7f266cb6314858e23a134d (patch)
tree2650d7923b9037dde05d46d21da5f2eefc020a77 /source4/script/tests/selftest.sh
parent46b829513a47dbb74fb0ea07ed85494da1480919 (diff)
downloadsamba-67c606b86314ada34b7f266cb6314858e23a134d.tar.gz
samba-67c606b86314ada34b7f266cb6314858e23a134d.tar.bz2
samba-67c606b86314ada34b7f266cb6314858e23a134d.zip
r7463: - move some more stuff into functions
- try to kill all jobs return by jobs -p metze (This used to be commit e4f5e52a8454fc2e6d5536e2cc9eb918c6c0e174)
Diffstat (limited to 'source4/script/tests/selftest.sh')
-rwxr-xr-xsource4/script/tests/selftest.sh29
1 files changed, 15 insertions, 14 deletions
diff --git a/source4/script/tests/selftest.sh b/source4/script/tests/selftest.sh
index b3198e0f46..dd6bd31fa5 100755
--- a/source4/script/tests/selftest.sh
+++ b/source4/script/tests/selftest.sh
@@ -12,6 +12,7 @@ then
fi
PREFIX=$1
+export PREFIX
TMPDIR=$PREFIX/tmp
LIBDIR=$PREFIX/lib
PIDDIR=$PREFIX/pid
@@ -20,6 +21,18 @@ PRIVATEDIR=$PREFIX/private
NCALRPCDIR=$PREFIX/ncalrpc
LOCKDIR=$PREFIX/lockdir
+SMBD_TEST_FIFO="$PREFIX/smbd_test.fifo"
+export SMBD_TEST_FIFO
+SMBD_TEST_LOG="$PREFIX/smbd_test.log"
+export SMBD_TEST_LOG
+
+DO_SOCKET_WRAPPER=$2
+if [ x"$DO_SOCKET_WRAPPER" = x"SOCKET_WRAPPER" ];then
+ SOCKET_WRAPPER_DIR="$PREFIX/socket_wrapper_dir"
+ export SOCKET_WRAPPER_DIR
+ echo "SOCKET_WRAPPER_DIR=$SOCKET_WRAPPER_DIR"
+fi
+
incdir=`dirname $0`
. $incdir/test_functions.sh
@@ -41,7 +54,7 @@ cat >$CONFFILE<<EOF
path = $TMPDIR
read only = no
ntvfs handler = posix
- posix:sharedelay = 5000
+ posix:sharedelay = 100000
EOF
ADDARG="-s $CONFFILE"
@@ -49,20 +62,8 @@ if [ x"$RUN_FROM_BUILD_FARM" = x"yes" ];then
ADDARG="$ADDARG --option=\"torture:progress=no\""
fi
-SMBD_TEST_FIFO="$PREFIX/smbd_test.fifo"
-export SMBD_TEST_FIFO
-
-rm -f $SMBD_TEST_FIFO
-mkfifo $SMBD_TEST_FIFO
-
-($SRCDIR/bin/smbd -d1 -s $CONFFILE -M single -i < $SMBD_TEST_FIFO;
- ret=$?;
- rm -f $SMBD_TEST_FIFO;
- echo "smbd exists with status $ret";
- exit $ret;
-)||exit $? &
+smbd_check_or_start
-sleep 2
START=`date`
(
failed=0