Fix bug #8458] - IE9 on Windows 7 cannot download files to samba 3.5.11 share
[Samba.git] / source3 / script / tests / test_net_misc.sh
blob015b5026a7f2a8d9bf9267ca7abdcc8ed98d943e
1 #!/bin/sh
3 # various tests for the "net" command
5 if [ $# -lt 3 ]; then
6 cat <<EOF
7 Usage: test_net_misc.sh SCRIPTDIR SERVERCONFFILE CONFIGURATION
8 EOF
9 exit 1;
12 SCRIPTDIR="$1"
13 SERVERCONFFILE="$2"
14 CONFIGURATION="$3"
16 NET="$VALGRIND ${NET:-$BINDIR/net} $CONFIGURATION"
18 NETTIME="${NET} time"
19 NETLOOKUP="${NET} lookup"
21 test x"$TEST_FUNCTIONS_SH" != x"INCLUDED" && {
22 incdir=`dirname $0`/../../../testprogs/blackbox
23 . $incdir/subunit.sh
26 failed=0
28 test_time()
30 PARAM="$1"
32 ${NETTIME} -S ${SERVER} ${PARAM}
35 test_lookup()
37 PARAM="$1"
39 ${NETLOOKUP} ${PARAM}
42 testit "get the time" \
43 test_time || \
44 failed=`expr $failed + 1`
46 testit "get the system time" \
47 test_time system || \
48 failed=`expr $failed + 1`
50 testit "get the time zone" \
51 test_time zone || \
52 failed=`expr $failed + 1`
54 testit "lookup the PDC" \
55 test_lookup pdc || \
56 failed=`expr $failed + 1`
58 testit "lookup the master browser" \
59 test_lookup master || \
60 failed=`expr $failed + 1`
62 testok $0 $failed