diff --git a/source4/script/tests/mktestdc.sh b/source4/script/tests/mktestdc.sh index 2068728a49e..da128574798 100755 --- a/source4/script/tests/mktestdc.sh +++ b/source4/script/tests/mktestdc.sh @@ -70,7 +70,7 @@ cat >$CONFFILE<$CONFFILE<$CONFFILE< /dev/null; then p=ldaps for options in "" "-U$USERNAME%$PASSWORD"; do - testit "TESTING PROTOCOL $p with options $options" ldap ../testprogs/blackbox/test_ldb.sh $p $SERVER $options + plantest "TESTING PROTOCOL $p with options $options" ldap ../testprogs/blackbox/test_ldb.sh $p $SERVER $options done fi for t in LDAP-CLDAP LDAP-BASIC LDAP-SCHEMA LDAP-UPTODATENESS do - testit "$t" ldap bin/smbtorture $TORTURE_OPTIONS "-U$USERNAME%$PASSWORD" //$SERVER/_none_ $t + plantest "$t" ldap bin/smbtorture $TORTURE_OPTIONS "-U$USERNAME%$PASSWORD" //$SERVER/_none_ $t done # only do the ldb tests when not in quick mode - they are quite slow, and ldb @@ -36,11 +36,9 @@ done test "$TORTURE_QUICK" = "yes" || { LDBDIR=lib/ldb export LDBDIR - testit "ldb" ldap $LDBDIR/tests/test-tdb.sh + plantest "ldb" ldap $LDBDIR/tests/test-tdb.sh } SCRIPTDIR=../testprogs/ejs -testit "ejs ldap" ldap $SCRIPTDIR/ldap.js $CONFIGURATION $SERVER -U$USERNAME%$PASSWORD - -testok $0 $failed +plantest "ejs ldap" ldap $SCRIPTDIR/ldap.js $CONFIGURATION $SERVER -U$USERNAME%$PASSWORD diff --git a/source4/script/tests/test_local.sh b/source4/script/tests/test_local.sh index e3ff3c80a66..57e11961bb8 100755 --- a/source4/script/tests/test_local.sh +++ b/source4/script/tests/test_local.sh @@ -22,11 +22,8 @@ incdir=`dirname $0` SMBD_TEST_FIFO="" export SMBD_TEST_FIFO -failed=0 for t in $local_tests; do - testit "$t" none $VALGRIND bin/smbtorture $TORTURE_OPTIONS ncalrpc: $t "$*" + plantest "$t" none $VALGRIND bin/smbtorture $TORTURE_OPTIONS ncalrpc: $t "$*" done -testit "tdb stress" none $VALGRIND bin/tdbtorture - -testok $0 $failed +plantest "tdb stress" none $VALGRIND bin/tdbtorture diff --git a/source4/script/tests/test_nbt.sh b/source4/script/tests/test_nbt.sh index a04feea0798..c3a09d4fb10 100755 --- a/source4/script/tests/test_nbt.sh +++ b/source4/script/tests/test_nbt.sh @@ -20,13 +20,11 @@ SCRIPTDIR=../testprogs/ejs PATH=bin:$PATH export PATH -testit "nmblookup -U $SERVER $SERVER" netbios bin/nmblookup $TORTURE_OPTIONS -U $SERVER $SERVER -testit "nmblookup $SERVER" netbios bin/nmblookup $TORTURE_OPTIONS $SERVER +plantest "nmblookup -U $SERVER $SERVER" netbios bin/nmblookup $TORTURE_OPTIONS -U $SERVER $SERVER +plantest "nmblookup $SERVER" netbios bin/nmblookup $TORTURE_OPTIONS $SERVER NBT_TESTS=`bin/smbtorture --list | grep ^NBT` for f in $NBT_TESTS; do - testit "$f" netbios bin/smbtorture $TORTURE_OPTIONS //$SERVER/_none_ $f -U$USERNAME%$PASSWORD + plantest "$f" netbios bin/smbtorture $TORTURE_OPTIONS //$SERVER/_none_ $f -U$USERNAME%$PASSWORD done - -testok $0 $failed diff --git a/source4/script/tests/test_net.sh b/source4/script/tests/test_net.sh index 05b42130ab1..b7b12c8b7ab 100755 --- a/source4/script/tests/test_net.sh +++ b/source4/script/tests/test_net.sh @@ -22,7 +22,6 @@ shift 4 incdir=`dirname $0` . $incdir/test_functions.sh -failed=0 for bindoptions in seal,padcheck $VALIDATE bigendian; do for transport in ncalrpc ncacn_np ncacn_ip_tcp; do case $transport in @@ -32,9 +31,7 @@ for bindoptions in seal,padcheck $VALIDATE bigendian; do esac for t in $tests; do name="$t on $transport with $bindoptions" - testit "$name" rpc $VALGRIND bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" -U"$username"%"$password" -W $domain $t "$*" + plantest "$name" rpc $VALGRIND bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" -U"$username"%"$password" -W $domain $t "$*" done done done - -testok $0 $failed diff --git a/source4/script/tests/test_pidl.sh b/source4/script/tests/test_pidl.sh index 2271b7b4d87..d143cd6b0a0 100755 --- a/source4/script/tests/test_pidl.sh +++ b/source4/script/tests/test_pidl.sh @@ -7,14 +7,10 @@ fi incdir=`dirname $0` . $incdir/test_functions.sh -failed=0 - if $PERL -e 'eval require Test::More;' > /dev/null 2>&1; then for f in pidl/tests/*.pl; do - testit "$f" none $PERL $f + plantest "$f" none $PERL $f done else echo "Skipping pidl tests - Test::More not installed" fi - -testok $0 $failed diff --git a/source4/script/tests/test_posix.sh b/source4/script/tests/test_posix.sh index 9fdfa981471..8faaac1a88e 100755 --- a/source4/script/tests/test_posix.sh +++ b/source4/script/tests/test_posix.sh @@ -30,5 +30,5 @@ for t in $tests; do continue; fi start="" - testit "$t" smb $VALGRIND bin/smbtorture $TORTURE_OPTIONS $ADDARGS $unc -U"$username"%"$password" $t + plantest "$t" smb $VALGRIND bin/smbtorture $TORTURE_OPTIONS $ADDARGS $unc -U"$username"%"$password" $t done diff --git a/source4/script/tests/test_quick.sh b/source4/script/tests/test_quick.sh index 14d7e0865b1..19dfab5730c 100755 --- a/source4/script/tests/test_quick.sh +++ b/source4/script/tests/test_quick.sh @@ -25,15 +25,11 @@ tests="$tests RAW-MKDIR RAW-SEEK RAW-OPEN RAW-WRITE" tests="$tests RAW-UNLINK RAW-READ RAW-CLOSE RAW-IOCTL RAW-RENAME" tests="$tests RAW-EAS RAW-STREAMS" -failed=0 for t in $tests; do if [ ! -z "$start" -a "$start" != $t ]; then continue; fi start="" name="$t" - testit "$name" base $VALGRIND bin/smbtorture $TORTURE_OPTIONS $ADDARGS $unc -U"$username"%"$password" $t + plantest "$name" base $VALGRIND bin/smbtorture $TORTURE_OPTIONS $ADDARGS $unc -U"$username"%"$password" $t done - -testok $0 $failed - diff --git a/source4/script/tests/test_rpc.sh b/source4/script/tests/test_rpc.sh index 21a238b7b30..3ee7fa9f352 100755 --- a/source4/script/tests/test_rpc.sh +++ b/source4/script/tests/test_rpc.sh @@ -25,7 +25,6 @@ shift 4 incdir=`dirname $0` . $incdir/test_functions.sh -failed=0 for bindoptions in seal,padcheck $VALIDATE bigendian; do for transport in ncalrpc ncacn_np ncacn_ip_tcp; do case $transport in @@ -35,7 +34,7 @@ for bindoptions in seal,padcheck $VALIDATE bigendian; do esac for t in $tests; do name="$t on $transport with $bindoptions" - testit "$name" rpc $VALGRIND bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" -U"$username"%"$password" -W $domain $t "$*" + plantest "$name" rpc $VALGRIND bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" -U"$username"%"$password" -W $domain $t "$*" done done done @@ -49,10 +48,7 @@ for bindoptions in connect $VALIDATE ; do esac for t in $tests; do name="$t on $transport with $bindoptions" - testit "$name" rpc $VALGRIND bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" -U"$username"%"$password" -W $domain $t "$*" + plantest "$name" rpc $VALGRIND bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" -U"$username"%"$password" -W $domain $t "$*" done done done - -testok $0 $failed - diff --git a/source4/script/tests/test_rpc_quick.sh b/source4/script/tests/test_rpc_quick.sh index e01c6d1d102..3526c53c3b4 100755 --- a/source4/script/tests/test_rpc_quick.sh +++ b/source4/script/tests/test_rpc_quick.sh @@ -22,7 +22,6 @@ shift 4 incdir=`dirname $0` . $incdir/test_functions.sh -failed=0 for bindoptions in seal,padcheck $VALIDATE bigendian; do for transport in ncalrpc ncacn_np ncacn_ip_tcp; do case $transport in @@ -32,9 +31,7 @@ for bindoptions in seal,padcheck $VALIDATE bigendian; do esac for t in $tests; do name="$t on $transport with $bindoptions" - testit "$name" rpc $VALGRIND bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" -U"$username"%"$password" -W $domain $t "$*" + plantest "$name" rpc $VALGRIND bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" -U"$username"%"$password" -W $domain $t "$*" done done done - -testok $0 $failed diff --git a/source4/script/tests/test_s3upgrade.sh b/source4/script/tests/test_s3upgrade.sh index 30b7ee06e4b..df7ae43c2aa 100755 --- a/source4/script/tests/test_s3upgrade.sh +++ b/source4/script/tests/test_s3upgrade.sh @@ -18,5 +18,5 @@ rm -f $PREFIX/* . script/tests/test_functions.sh -testit "parse samba3" none bin/smbscript ../testdata/samba3/verify $CONFIGURATION ../testdata/samba3 -#testit "upgrade" none bin/smbscript setup/upgrade $CONFIGURATION --verify --targetdir=$PREFIX ../testdata/samba3 ../testdata/samba3/smb.conf +plantest "parse samba3" none bin/smbscript ../testdata/samba3/verify $CONFIGURATION ../testdata/samba3 +#plantest "upgrade" none bin/smbscript setup/upgrade $CONFIGURATION --verify --targetdir=$PREFIX ../testdata/samba3 ../testdata/samba3/smb.conf diff --git a/source4/script/tests/test_session_key.sh b/source4/script/tests/test_session_key.sh index ca568c3516e..e9ce143eaaf 100755 --- a/source4/script/tests/test_session_key.sh +++ b/source4/script/tests/test_session_key.sh @@ -17,7 +17,6 @@ shift 5 incdir=`dirname $0` . $incdir/test_functions.sh -failed=0 transport="ncacn_np" for bindoptions in bigendian seal; do for keyexchange in "yes" "no"; do @@ -37,18 +36,17 @@ for bindoptions in bigendian seal; do "-k no --option=gensec:spnego=no --option=clientntlmv2auth=yes" \ "-k no --option=usespnego=no"; do name="RPC-SECRETS on $transport with $bindoptions with NTLM2:$ntlm2 KEYEX:$keyexchange LM_KEY:$lm_key $ntlmoptions" - testit "$name" rpc bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" --option=ntlmssp_client:keyexchange=$keyexchange --option=ntlmssp_client:ntlm2=$ntlm2 --option=ntlmssp_client:lm_key=$lm_key $ntlmoptions -U"$username"%"$password" -W $domain --option=gensec:target_hostname=$netbios_name RPC-SECRETS "$*" + plantest "$name" rpc bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" --option=ntlmssp_client:keyexchange=$keyexchange --option=ntlmssp_client:ntlm2=$ntlm2 --option=ntlmssp_client:lm_key=$lm_key $ntlmoptions -U"$username"%"$password" -W $domain --option=gensec:target_hostname=$netbios_name RPC-SECRETS "$*" done done done done name="RPC-SECRETS on $transport with $bindoptions with Kerberos" - testit "$name" rpc bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" -k yes -U"$username"%"$password" -W $domain "--option=gensec:target_hostname=$netbios_name" RPC-SECRETS "$*" + plantest "$name" rpc bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" -k yes -U"$username"%"$password" -W $domain "--option=gensec:target_hostname=$netbios_name" RPC-SECRETS "$*" name="RPC-SECRETS on $transport with $bindoptions with Kerberos - use target principal" - testit "$name" rpc bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" -k yes -U"$username"%"$password" -W $domain "--option=clientusespnegoprincipal=yes" "--option=gensec:target_hostname=$netbios_name" RPC-SECRETS "$*" + plantest "$name" rpc bin/smbtorture $TORTURE_OPTIONS $transport:"$server[$bindoptions]" -k yes -U"$username"%"$password" -W $domain "--option=clientusespnegoprincipal=yes" "--option=gensec:target_hostname=$netbios_name" RPC-SECRETS "$*" done name="RPC-SECRETS on $transport with Kerberos - use Samba3 style login" - testit "$name" rpc bin/smbtorture $TORTURE_OPTIONS $transport:"$server" -k yes -U"$username"%"$password" -W $domain "--option=gensec:fake_gssapi_krb5=yes" "--option=gensec:gssapi_krb5=no" "--option=gensec:target_hostname=$netbios_name" RPC-SECRETS "$*" + plantest "$name" rpc bin/smbtorture $TORTURE_OPTIONS $transport:"$server" -k yes -U"$username"%"$password" -W $domain "--option=gensec:fake_gssapi_krb5=yes" "--option=gensec:gssapi_krb5=no" "--option=gensec:target_hostname=$netbios_name" RPC-SECRETS "$*" name="RPC-SECRETS on $transport with Kerberos - use Samba3 style login, use target principal" - testit "$name" rpc bin/smbtorture $TORTURE_OPTIONS $transport:"$server" -k yes -U"$username"%"$password" -W $domain "--option=clientusespnegoprincipal=yes" "--option=gensec:fake_gssapi_krb5=yes" "--option=gensec:gssapi_krb5=no" "--option=gensec:target_hostname=$netbios_name" RPC-SECRETS "$*" -testok $0 $failed + plantest "$name" rpc bin/smbtorture $TORTURE_OPTIONS $transport:"$server" -k yes -U"$username"%"$password" -W $domain "--option=clientusespnegoprincipal=yes" "--option=gensec:fake_gssapi_krb5=yes" "--option=gensec:gssapi_krb5=no" "--option=gensec:target_hostname=$netbios_name" RPC-SECRETS "$*" diff --git a/source4/script/tests/test_simple.sh b/source4/script/tests/test_simple.sh index cec4f7f4c9d..56db719001f 100755 --- a/source4/script/tests/test_simple.sh +++ b/source4/script/tests/test_simple.sh @@ -20,15 +20,11 @@ incdir=`dirname $0` tests="BASE-RW1" -failed=0 for t in $tests; do if [ ! -z "$start" -a "$start" != $t ]; then continue; fi start="" name="$t" - testit "$name" smb $VALGRIND bin/smbtorture $TORTURE_OPTIONS $ADDARGS $unc -U"$username"%"$password" $t + plantest "$name" smb $VALGRIND bin/smbtorture $TORTURE_OPTIONS $ADDARGS $unc -U"$username"%"$password" $t done - -testok $0 $failed - diff --git a/source4/script/tests/test_swig.sh b/source4/script/tests/test_swig.sh index c98caeb43ee..9f5e7c0ebf0 100755 --- a/source4/script/tests/test_swig.sh +++ b/source4/script/tests/test_swig.sh @@ -10,8 +10,6 @@ fi incdir=`dirname $0` . $incdir/test_functions.sh -failed=0 - export PYTHONPATH=lib/tdb/swig:lib/ldb/swig:scripting/swig:$PYTHONPATH export LD_LIBRARY_PATH=bin:$LD_LIBRARY_PATH @@ -20,5 +18,3 @@ scripting/swig/torture/torture_tdb.py echo Testing ldb wrappers scripting/swig/torture/torture_ldb.py - -testok $0 $failed diff --git a/source4/script/tests/test_w2k3.sh b/source4/script/tests/test_w2k3.sh index 122e3ea7a74..b262029892f 100755 --- a/source4/script/tests/test_w2k3.sh +++ b/source4/script/tests/test_w2k3.sh @@ -26,8 +26,6 @@ incdir=`dirname $0` OPTIONS="-U$username%$password -W $domain --option realm=$realm" -failed=0 - name="RPC-SPOOLSS on ncacn_np" testit "$name" rpc bin/smbtorture $TORTURE_OPTIONS ncacn_np:"$server" $OPTIONS RPC-SPOOLSS "$*" @@ -48,5 +46,3 @@ name="RPC-DRSUAPI on ncacn_ip_tcp with seal" testit "$name" rpc bin/smbtorture $TORTURE_OPTIONS ncacn_ip_tcp:"$server[seal]" $OPTIONS RPC-DRSUAPI "$*" name="RPC-DRSUAPI on ncacn_ip_tcp with seal,bigendian" testit "$name" rpc bin/smbtorture $TORTURE_OPTIONS ncacn_ip_tcp:"$server[seal,bigendian]" $OPTIONS RPC-DRSUAPI "$*" - -testok $0 $failed diff --git a/source4/script/tests/test_w2k3_file.sh b/source4/script/tests/test_w2k3_file.sh index e39d9b86329..f008d491283 100755 --- a/source4/script/tests/test_w2k3_file.sh +++ b/source4/script/tests/test_w2k3_file.sh @@ -39,7 +39,6 @@ fail="RAW-SEARCH RAW-ACLS RAW-QFSINFO" echo "Skipping tests expected to fail: $fail" -failed=0 for t in $tests; do if [ ! -z "$start" -a "$start" != $t ]; then continue; @@ -48,5 +47,3 @@ for t in $tests; do name="$t" testit "$name" smb $VALGRIND bin/smbtorture $TORTURE_OPTIONS $ADDARGS $unc -U"$username"%"$password" $t done - -testok $0 $failed diff --git a/source4/script/tests/tests_win.sh b/source4/script/tests/tests_win.sh index b885056ace9..e25c29d4c9b 100755 --- a/source4/script/tests/tests_win.sh +++ b/source4/script/tests/tests_win.sh @@ -1,7 +1,7 @@ #!/bin/sh if [ `whoami` != "root" ]; then - echo "Windows tests will not run without root privilages." + echo "Windows tests will not run without root privileges." exit 1 fi