Use socket wrapper for selftest.pl, find binaries correctly.
authorJelmer Vernooij <jelmer@samba.org>
Tue, 21 Oct 2008 15:48:05 +0000 (17:48 +0200)
committerJelmer Vernooij <jelmer@samba.org>
Tue, 21 Oct 2008 15:48:05 +0000 (17:48 +0200)
selftest/selftest.pl
source3/Makefile.in
source3/selftest/skip
source3/selftest/tests.sh

index b1908d456cbd28c54241b08d848cac2b1d20e039..96b58cceceb71e324127b1ff2a2e57503fa14a60 100755 (executable)
@@ -300,14 +300,12 @@ Target Specific:
  --socket-wrapper-keep-pcap keep all pcap files, not just those for tests that 
                             failed
  --socket-wrapper           enable socket wrapper
+ --bindir=PATH              path to target binaries
  --expected-failures=FILE   specify list of tests that is guaranteed to fail
 
 Samba4 Specific:
  --ldap=openldap|fedora-ds  back samba onto specified ldap server
 
-Samba3 Specific:
- --bindir=PATH              path to binaries
-
 Kvm Specific:
  --image=PATH               path to KVM image
 
@@ -447,12 +445,13 @@ if ($opt_target eq "samba4") {
        require target::Samba4;
        $target = new Samba4($opt_bindir or "$srcdir/bin", $ldap, "$srcdir/setup");
 } elsif ($opt_target eq "samba3") {
-       if ($opt_socket_wrapper and `$opt_bindir/smbd -b | grep SOCKET_WRAPPER` eq "") {
+       my $bindir = ($opt_bindir or "$srcdir/bin");
+       if ($opt_socket_wrapper and `$bindir/smbd -b | grep SOCKET_WRAPPER` eq "") {
                die("You must include --enable-socket-wrapper when compiling Samba in order to execute 'make test'.  Exiting....");
        }
        $testenv_default = "dc";
        require target::Samba3;
-       $target = new Samba3($opt_bindir);
+       $target = new Samba3($bindir);
 } elsif ($opt_target eq "win") {
        die("Windows tests will not run with socket wrapper enabled.") 
                if ($opt_socket_wrapper);
index ac330b39ff551929c9932e00a439548fdffd850d..09c1dd7b351010daa07524b7074be537bf34d832 100644 (file)
@@ -2811,7 +2811,8 @@ selftest:: all torture timelimit
        @../selftest/selftest.pl --prefix=st --target=samba3 \
                --testlist="$(srcdir)/selftest/tests.sh|" \
                --expected-failures=$(srcdir)/selftest/knownfail \
-               --exclude=$(srcdir)/selftest/skip 
+               --exclude=$(srcdir)/selftest/skip \
+               --socket-wrapper
 
 # Check for Winbind struct 32/64bit padding
 test_wbpad:
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..152c076ec7205b97413ce2128c55db8530302e42 100644 (file)
@@ -0,0 +1,15 @@
+samba3.smbconftort     # Errors, needs smb.conf file
+samba3.randomipc
+samba3.negnowait
+samba3.nbench
+samba3.errmapextract
+samba3.trans2scan
+samba3.nttransscan
+samba3.deny1
+samba3.deny2
+samba3.openattr
+samba3.casetable
+samba3.eatest
+samba3.mangle
+samba3.utable
+samba3.pipe_number
index 01f87debd0bad86fa63497ce82e8b08073f8289a..65ecfc0b5dbe5f7575fdd25de34184afbac86faa 100755 (executable)
@@ -49,4 +49,20 @@ BINDIR=`dirname $0`/../bin
 plantest "talloctort" none $VALGRIND $BINDIR/talloctort 
 plantest "replacetort" none $VALGRIND $BINDIR/replacetort
 plantest "tdbtorture" none $VALGRIND $BINDIR/tdbtorture
-#plantest "smbconftort" none $VALGRIND $BINDIR/smbconftort $CONFIGURATION
+plantest "smbconftort" none $VALGRIND $BINDIR/smbconftort $CONFIGURATION
+
+tests="FDPASS LOCK1 LOCK2 LOCK3 LOCK4 LOCK5 LOCK6 LOCK7"
+tests="$tests UNLINK BROWSE ATTR TRANS2 TORTURE "
+tests="$tests OPLOCK1 OPLOCK2 OPLOCK3"
+tests="$tests DIR DIR1 TCON TCONDEV RW1 RW2 RW3"
+tests="$tests OPEN XCOPY RENAME DELETE PROPERTIES W2K"
+tests="$tests TCON2 IOCTL CHKPATH FDSESS LOCAL-SUBSTITUTE"
+
+for t in $tests; do
+    plantest "$t" dc $VALGRIND $BINDIR/smbtorture \$UNC -U"\$USERNAME"%"\$PASSWORD" $t
+done
+
+plantest "blackbox.smbclient" dc script/tests/test_smbclient_s3.sh \$SERVER \$SERVER_IP
+plantest "blackbox.wbinfo" dc script/tests/test_wbinfo_s3.sh \$DOMAIN \$SERVER \$USERNAME \$PASSWORD
+plantest "blackbox.net" dc script/tests/test_net_s3.sh
+