• Home
  • History
  • Annotate
  • Line#
  • Navigate
  • Raw
  • Download
  • only in /asuswrt-rt-n18u-9.0.0.4.380.2695/release/src/router/samba-3.5.8/source3/script/tests/
1#!/bin/sh
2
3if [ $# -lt 4 ]; then
4cat <<EOF
5Usage: test_wbinfo_s3.sh DOMAIN SERVER USERNAME PASSWORD <wbinfo args>
6EOF
7exit 1;
8fi
9
10domain="$1"
11server="$2"
12username="$3"
13password="$4"
14shift 4
15ADDARGS="$*"
16
17test x"$TEST_FUNCTIONS_SH" != x"INCLUDED" && {
18incdir=`dirname $0`
19. $incdir/test_functions.sh
20}
21
22OLDIFS=$IFS;
23
24tests="--ping"
25tests="$tests:--separator"
26tests="$tests:--own-domain"
27tests="$tests:--all-domains"
28tests="$tests:--trusted-domains"
29tests="$tests:--domain-info=BUILTIN"
30tests="$tests:--domain-info=$domain"
31tests="$tests:--online-status"
32tests="$tests:--online-status --domain=BUILTIN"
33tests="$tests:--online-status --domain=$domain"
34#Didn't pass yet# tests="$tests:--domain-users"
35tests="$tests:--domain-groups"
36tests="$tests:--name-to-sid=$username"
37#Didn't pass yet# tests="$tests:--user-info=$username"
38tests="$tests:--user-groups=$username"
39tests="$tests:--allocate-uid"
40tests="$tests:--allocate-gid"
41
42failed=0
43
44OLDIFS=$IFS
45NEWIFS=$':'
46IFS=$NEWIFS
47for t in $tests; do
48   IFS=$OLDIFS
49   testit "wbinfo $t" $VALGRIND $BINDIR/wbinfo $ADDARGS $t || failed=`expr $failed + 1`
50   IFS=$NEWIFS
51done
52IFS=$OLDIFS
53
54testok $0 $failed
55