summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2008-06-14 12:15:24 +0200
committerJelmer Vernooij <jelmer@samba.org>2008-06-14 12:15:24 +0200
commit5bc9ef0e33ed2827cbd2ab03b58a6de9220ad86d (patch)
treea07a881a92369f934549ee5d04d1f0fc5f0ff65a
parent21a11373e05c3278d05f56c4ee5940f31045a7ab (diff)
parentf3fb381952e6afd4b3d15758eaf3aaf29a112eec (diff)
downloadsamba-5bc9ef0e33ed2827cbd2ab03b58a6de9220ad86d.tar.gz
samba-5bc9ef0e33ed2827cbd2ab03b58a6de9220ad86d.tar.bz2
samba-5bc9ef0e33ed2827cbd2ab03b58a6de9220ad86d.zip
Merge branch 'v4-0-test' of ssh://git.samba.org/data/git/samba into v4-0-fixmodulesdir
(This used to be commit 168bb8473c0cfeb388f9955059f92410b8ba5d06)
-rwxr-xr-xsource4/selftest/samba4_tests.sh1
-rwxr-xr-xtestprogs/blackbox/test_wintest.sh45
-rw-r--r--testprogs/blackbox/wintest/wintest.conf7
3 files changed, 53 insertions, 0 deletions
diff --git a/source4/selftest/samba4_tests.sh b/source4/selftest/samba4_tests.sh
index 1d550cbfe1..e9fbede4fb 100755
--- a/source4/selftest/samba4_tests.sh
+++ b/source4/selftest/samba4_tests.sh
@@ -279,6 +279,7 @@ plantest "blackbox.masktest" dc $bbdir/test_masktest.sh "\$SERVER" "\$USERNAME"
plantest "blackbox.gentest" dc $bbdir/test_gentest.sh "\$SERVER" "\$USERNAME" "\$PASSWORD" "\$DOMAIN" "$PREFIX"
plantest "blackbox.wbinfo" dc $bbdir/test_wbinfo.sh "\$DOMAIN" "\$USERNAME" "\$PASSWORD" "dc"
plantest "blackbox.wbinfo" member $bbdir/test_wbinfo.sh "\$DOMAIN" "\$DC_USERNAME" "\$DC_PASSWORD" "member"
+plantest "blackbox.wintest" none $bbdir/test_wintest.sh "$TORTURE_OPTIONS"
# Tests using the "Simple" NTVFS backend
diff --git a/testprogs/blackbox/test_wintest.sh b/testprogs/blackbox/test_wintest.sh
new file mode 100755
index 0000000000..8bbe4f2984
--- /dev/null
+++ b/testprogs/blackbox/test_wintest.sh
@@ -0,0 +1,45 @@
+#!/bin/sh
+# Blackbox tests for testing against windows machines
+# Copyright (C) 2008 Jim McDonough
+
+
+testwithconf() {
+# define test variables, startup/shutdown scripts
+. $1
+shift 1
+
+if [ -n "$WINTEST_STARTUP" ]; then
+. $WINTEST_STARTUP;
+fi
+
+testit "smbtorture" $smbtorture //$SERVER/$SHARE RAW-OPEN -W "$DOMAIN" -U"$USERNAME%$PASSWORD" $@ || failed=`expr $failed + 1`
+
+if [ -n "$WINTEST_SHUTDOWN" ]; then
+. $WINTEST_SHUTDOWN;
+fi
+}
+
+
+# main
+# skip without WINTEST_CONF_DIR
+if [ -z "$WINTEST_CONF_DIR" ]; then
+exit 0;
+fi
+
+SOCKET_WRAPPER_DIR=
+export -n SOCKET_WRAPPER_DIR
+
+failed=0
+
+$basedir=`pwd`
+
+samba4bindir=`dirname $0`/../../source/bin
+smbtorture=$samba4bindir/smbtorture
+
+. `dirname $0`/subunit.sh
+
+for wintest_conf in $WINTEST_CONF_DIR/*.conf; do
+testwithconf "$wintest_conf" $@;
+done
+
+exit $failed
diff --git a/testprogs/blackbox/wintest/wintest.conf b/testprogs/blackbox/wintest/wintest.conf
new file mode 100644
index 0000000000..d1403662f9
--- /dev/null
+++ b/testprogs/blackbox/wintest/wintest.conf
@@ -0,0 +1,7 @@
+#export WINTEST_STARTUP="/tmp/startup client"
+#export WINTEST_SHUTDOWN=/tmp/shutdown client"
+export DOMAIN="client"
+export USERNAME="administrator"
+export PASSWORD="samba"
+export SERVER="192.168.213.161"
+export SHARE="c\$" \ No newline at end of file