summaryrefslogtreecommitdiff
path: root/source3/script/tests/test_wbinfo_s3.sh
diff options
context:
space:
mode:
Diffstat (limited to 'source3/script/tests/test_wbinfo_s3.sh')
-rwxr-xr-xsource3/script/tests/test_wbinfo_s3.sh48
1 files changed, 48 insertions, 0 deletions
diff --git a/source3/script/tests/test_wbinfo_s3.sh b/source3/script/tests/test_wbinfo_s3.sh
new file mode 100755
index 0000000000..abd6146e1a
--- /dev/null
+++ b/source3/script/tests/test_wbinfo_s3.sh
@@ -0,0 +1,48 @@
+#!/bin/sh
+
+if [ $# -lt 4 ]; then
+cat <<EOF
+Usage: test_wbinfo_s3.sh DOMAIN SERVER USERNAME PASSWORD <wbinfo args>
+EOF
+exit 1;
+fi
+
+domain="$1"
+server="$2"
+username="$3"
+password="$4"
+shift 4
+ADDARGS="$*"
+
+incdir=`dirname $0`
+. $incdir/test_functions.sh
+
+OLDIFS=$IFS;
+
+tests="--ping"
+tests="$tests:--separator"
+tests="$tests:--own-domain"
+tests="$tests:--all-domains"
+tests="$tests:--trusted-domains"
+tests="$tests:--domain-info=BUILTIN"
+tests="$tests:--domain-info=$server"
+tests="$tests:--sequence"
+tests="$tests:--sequence --domain=BUILTIN"
+tests="$tests:--sequence --domain=$server"
+#Didn't pass yet# tests="$tests:--domain-users"
+tests="$tests:--domain-groups"
+tests="$tests:--name-to-sid=$username"
+#Didn't pass yet# tests="$tests:--user-info=$username"
+tests="$tests:--user-groups=$username"
+
+OLDIFS=$IFS
+NEWIFS=$':'
+IFS=$NEWIFS
+for t in $tests; do
+ IFS=$OLDIFS
+ testit "wbinfo $t" $VALGRIND $BINDIR/wbinfo $ADDARGS $t || failed=`expr $failed + 1`
+ IFS=$NEWIFS
+done
+IFS=$OLDIFS
+
+testok $0 $failed