From 9ce2b9a79ba34705bcd8c32db1e084763702faec Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Sat, 11 Jun 2005 04:07:20 +0000 Subject: [PATCH] r7485: - allow test_xxx.sh to run outside of 'make test' by ensuring $PREFIX is setup - use loopback interface only, otherwise nbtd will answer with a real ip, which the socket wrapper code will fail to connect to - enable eadb for posix testing - sleeping to wait for smbd to start is pointless, as smbd won't start till its fifo is opened due to the fifo redirection on stdin - sleep for a few seconds to allow for nbt server to register names after opening fifo - use bcast name resolution, so we don't rely on /etc/hosts being right --- source/script/tests/selftest.sh | 7 +++++++ source/script/tests/test_functions.sh | 7 +++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/source/script/tests/selftest.sh b/source/script/tests/selftest.sh index c974decd6c4..ac3fd71f947 100755 --- a/source/script/tests/selftest.sh +++ b/source/script/tests/selftest.sh @@ -50,12 +50,15 @@ cat >$CONFFILE<>$SMBD_TEST_LOG; exit $ret; ) || exit $? &) 2>/dev/null || exit $? - sleep 2 echo "DONE" fi return 0; @@ -55,7 +54,11 @@ smbd_have_test_log() { } testit() { - name=$1 + if [ -z "$PREFIX" ]; then + PREFIX=test_prefix + mkdir -p $PREFIX + fi + name=$1 shift 1 SMBD_IS_UP="no" TEST_LOG="$PREFIX/test_log.$$" -- 2.11.4.GIT