summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2011-09-11 08:16:50 +1000
committerAndrew Bartlett <abartlet@samba.org>2011-09-12 20:42:22 +1000
commit28ad50e5fd1887fff149d05793b2dabe5a08051a (patch)
tree33fe1c6cac33bfa414052ca80e1a77e78b47c8ca /source3
parente223a65b1011f82687e2fdfa102f305e1fd76214 (diff)
downloadsamba-28ad50e5fd1887fff149d05793b2dabe5a08051a.tar.gz
samba-28ad50e5fd1887fff149d05793b2dabe5a08051a.tar.bz2
samba-28ad50e5fd1887fff149d05793b2dabe5a08051a.zip
s3-selftest: Set path to bin/net and bin/wbinfo in command line to test scripts
This makes it easier to reproduce these tests outside the test environment, as we rely less on environment variables. Andrew Bartlett
Diffstat (limited to 'source3')
-rwxr-xr-xsource3/script/tests/test_net_conf.sh7
-rwxr-xr-xsource3/script/tests/test_net_misc.sh5
-rwxr-xr-xsource3/script/tests/test_net_registry.sh7
-rwxr-xr-xsource3/script/tests/test_net_registry_roundtrip.sh9
-rwxr-xr-xsource3/script/tests/test_smbclient_s3.sh7
-rwxr-xr-xsource3/selftest/tests.py24
6 files changed, 32 insertions, 27 deletions
diff --git a/source3/script/tests/test_net_conf.sh b/source3/script/tests/test_net_conf.sh
index ee2903be02..6d3d2a1eec 100755
--- a/source3/script/tests/test_net_conf.sh
+++ b/source3/script/tests/test_net_conf.sh
@@ -6,15 +6,16 @@
if [ $# -lt 3 ]; then
cat <<EOF
-Usage: test_net_conf.sh SCRIPTDIR SERVERCONFFILE CONFIGURATION [rpc]
+Usage: test_net_conf.sh SCRIPTDIR SERVERCONFFILE NET CONFIGURATION [rpc]
EOF
exit 1;
fi
SCRIPTDIR="$1"
SERVERCONFFILE="$2"
-CONFIGURATION="$3"
-RPC="$4"
+NET="$3"
+CONFIGURATION="$4"
+RPC="$5"
LOGDIR_PREFIX="conf_test"
diff --git a/source3/script/tests/test_net_misc.sh b/source3/script/tests/test_net_misc.sh
index 82775dc4d3..566694be74 100755
--- a/source3/script/tests/test_net_misc.sh
+++ b/source3/script/tests/test_net_misc.sh
@@ -4,14 +4,15 @@
if [ $# -lt 3 ]; then
cat <<EOF
-Usage: test_net_misc.sh SCRIPTDIR SERVERCONFFILE CONFIGURATION
+Usage: test_net_misc.sh SCRIPTDIR SERVERCONFFILE NET CONFIGURATION
EOF
exit 1;
fi
SCRIPTDIR="$1"
SERVERCONFFILE="$2"
-CONFIGURATION="$3"
+NET="$3"
+CONFIGURATION="$4"
NET="$VALGRIND ${NET:-$BINDIR/net} $CONFIGURATION"
diff --git a/source3/script/tests/test_net_registry.sh b/source3/script/tests/test_net_registry.sh
index b76a988b4d..5158d61275 100755
--- a/source3/script/tests/test_net_registry.sh
+++ b/source3/script/tests/test_net_registry.sh
@@ -9,15 +9,16 @@
if [ $# -lt 3 ]; then
cat <<EOF
-Usage: test_net_registry.sh SCRIPTDIR SERVERCONFFILE CONFIGURATION RPC
+Usage: test_net_registry.sh SCRIPTDIR SERVERCONFFILE NET CONFIGURATION RPC
EOF
exit 1;
fi
SCRIPTDIR="$1"
SERVERCONFFILE="$2"
-CONFIGURATION="$3"
-RPC="$4"
+NET="$3"
+CONFIGURATION="$4"
+RPC="$5"
NET="$VALGRIND ${NET:-$BINDIR/net} $CONFIGURATION"
diff --git a/source3/script/tests/test_net_registry_roundtrip.sh b/source3/script/tests/test_net_registry_roundtrip.sh
index 72bc693557..050311a814 100755
--- a/source3/script/tests/test_net_registry_roundtrip.sh
+++ b/source3/script/tests/test_net_registry_roundtrip.sh
@@ -7,17 +7,18 @@
if [ $# -lt 3 ]; then
cat <<EOF
-Usage: test_net_registry_roundtrip.sh SCRIPTDIR SERVERCONFFILE PREFIX CONFIGURATION
+Usage: test_net_registry_roundtrip.sh SCRIPTDIR SERVERCONFFILE NET CONFIGURATION RPC
EOF
exit 1;
fi
SCRIPTDIR="$1"
SERVERCONFFILE="$2"
-CONFIGURATION="$3"
-RPC="$4"
+NET="$3"
+CONFIGURATION="$4"
+RPC="$5"
-NET="$VALGRIND ${NET:-$BINDIR/net} $CONFIGURATION"
+NET="$VALGRIND ${NET} $CONFIGURATION"
if test "x${RPC}" = "xrpc" ; then
NETCMD="${NET} -U${USERNAME}%${PASSWORD} -I ${SERVER_IP} rpc"
diff --git a/source3/script/tests/test_smbclient_s3.sh b/source3/script/tests/test_smbclient_s3.sh
index 05bc8ef4e9..d2c504908b 100755
--- a/source3/script/tests/test_smbclient_s3.sh
+++ b/source3/script/tests/test_smbclient_s3.sh
@@ -4,7 +4,7 @@
if [ $# -lt 7 ]; then
cat <<EOF
-Usage: test_smbclient_s3.sh SERVER SERVER_IP DOMAIN USERNAME PASSWORD USERID LOCAL_PATH PREFIX SMBCLIENT
+Usage: test_smbclient_s3.sh SERVER SERVER_IP DOMAIN USERNAME PASSWORD USERID LOCAL_PATH PREFIX SMBCLIENT WBINFO
EOF
exit 1;
fi
@@ -18,9 +18,10 @@ USERID="$6"
LOCAL_PATH="$7"
PREFIX="$8"
SMBCLIENT="$9"
+WBINFO="$10"
SMBCLIENT="$VALGRIND ${SMBCLIENT}"
-WBINFO="$VALGRIND ${WBINFO:-$BINDIR/wbinfo}"
-shift 9
+WBINFO="$VALGRIND ${WBINFO}"
+shift 10
ADDARGS="$*"
incdir=`dirname $0`/../../../testprogs/blackbox
diff --git a/source3/selftest/tests.py b/source3/selftest/tests.py
index dba4713d4c..ff350eba4c 100755
--- a/source3/selftest/tests.py
+++ b/source3/selftest/tests.py
@@ -116,38 +116,38 @@ plantestsuite("samba3.blackbox.smbclient_auth.plain (%s) bad username" % env, en
# plain
for env in ["s3dc"]:
- plantestsuite("samba3.blackbox.smbclient_s3.plain (%s)" % env, env, [os.path.join(samba3srcdir, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$DC_USERNAME', '$DC_PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', binpath('smbclient3'), configuration])
+ plantestsuite("samba3.blackbox.smbclient_s3.plain (%s)" % env, env, [os.path.join(samba3srcdir, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$DC_USERNAME', '$DC_PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', binpath('smbclient3'), binpath('wbinfo'), configuration])
for env in ["member"]:
- plantestsuite("samba3.blackbox.smbclient_s3.plain (%s) member creds" % env, env, [os.path.join(samba3srcdir, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$SERVER', '$SERVER\\\\$USERNAME', '$PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', binpath('smbclient3'), configuration])
+ plantestsuite("samba3.blackbox.smbclient_s3.plain (%s) member creds" % env, env, [os.path.join(samba3srcdir, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$SERVER', '$SERVER\\\\$USERNAME', '$PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', binpath('smbclient3'), binpath('wbinfo'), configuration])
for env in ["s3dc"]:
- plantestsuite("samba3.blackbox.smbclient_s3.sign (%s)" % env, env, [os.path.join(samba3srcdir, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$DC_USERNAME', '$DC_PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', binpath('smbclient3'), configuration, "--signing=required"])
+ plantestsuite("samba3.blackbox.smbclient_s3.sign (%s)" % env, env, [os.path.join(samba3srcdir, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$DC_USERNAME', '$DC_PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', binpath('smbclient3'), binpath('wbinfo'), configuration, "--signing=required"])
for env in ["member"]:
- plantestsuite("samba3.blackbox.smbclient_s3.sign (%s) member creds" % env, env, [os.path.join(samba3srcdir, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$SERVER', '$SERVER\\\\$USERNAME', '$PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', binpath('smbclient3'), configuration, "--signing=required"])
+ plantestsuite("samba3.blackbox.smbclient_s3.sign (%s) member creds" % env, env, [os.path.join(samba3srcdir, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$SERVER', '$SERVER\\\\$USERNAME', '$PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', binpath('smbclient3'), binpath('wbinfo'), configuration, "--signing=required"])
# encrypted
for env in ["s3dc"]:
- plantestsuite("samba3.blackbox.smbclient_s3.crypt (%s)" % env, env, [os.path.join(samba3srcdir, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$USERNAME', '$PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', binpath('smbclient3'), configuration, "-e"])
+ plantestsuite("samba3.blackbox.smbclient_s3.crypt (%s)" % env, env, [os.path.join(samba3srcdir, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$USERNAME', '$PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', binpath('smbclient3'), binpath('wbinfo'), configuration, "-e"])
#TODO encrypted against member, with member creds, and with DC creds
plantestsuite("samba3.blackbox.net.misc", "s3dc:local", [os.path.join(samba3srcdir, "script/tests/test_net_misc.sh"),
- scriptdir, "$SMB_CONF_PATH", configuration])
+ scriptdir, "$SMB_CONF_PATH", binpath('net'), configuration])
plantestsuite("samba3.blackbox.net.local.registry", "s3dc:local", [os.path.join(samba3srcdir, "script/tests/test_net_registry.sh"),
- scriptdir, "$SMB_CONF_PATH", configuration])
+ scriptdir, "$SMB_CONF_PATH", binpath('net'), configuration])
plantestsuite("samba3.blackbox.net.rpc.registry", "s3dc", [os.path.join(samba3srcdir, "script/tests/test_net_registry.sh"),
- scriptdir, "$SMB_CONF_PATH", configuration, 'rpc'])
+ scriptdir, "$SMB_CONF_PATH", binpath('net'), configuration, 'rpc'])
plantestsuite("samba3.blackbox.net.local.registry.roundtrip", "s3dc:local", [os.path.join(samba3srcdir, "script/tests/test_net_registry_roundtrip.sh"),
- scriptdir, "$SMB_CONF_PATH", configuration,])
+ scriptdir, "$SMB_CONF_PATH", binpath('net'), configuration,])
plantestsuite("samba3.blackbox.net.rpc.registry.roundtrip", "s3dc", [os.path.join(samba3srcdir, "script/tests/test_net_registry_roundtrip.sh"),
- scriptdir, "$SMB_CONF_PATH", configuration, 'rpc'])
+ scriptdir, "$SMB_CONF_PATH", binpath('net'), configuration, 'rpc'])
plantestsuite("samba3.blackbox.net.local.conf", "s3dc:local", [os.path.join(samba3srcdir, "script/tests/test_net_conf.sh"),
- scriptdir, "$SMB_CONF_PATH", configuration,])
+ scriptdir, "$SMB_CONF_PATH", binpath('net'), configuration,])
plantestsuite("samba3.blackbox.net.rpc.conf", "s3dc", [os.path.join(samba3srcdir, "script/tests/test_net_conf.sh"),
- scriptdir, "$SMB_CONF_PATH", configuration, 'rpc'])
+ scriptdir, "$SMB_CONF_PATH", binpath('net'), configuration, 'rpc'])
plantestsuite("samba3.blackbox.testparm", "s3dc:local", [os.path.join(samba3srcdir, "script/tests/test_testparm_s3.sh"),