[SCM] Samba Shared Repository - branch master updated

Jeremy Allison jra at samba.org
Thu Feb 27 19:35:03 UTC 2020


The branch, master has been updated
       via  cb37caaa56a selftest: Run libsmbclient with and without unix extensions
       via  bb5cf674762 selftest: Introduce planlibsmbclienttest()
       via  ac65874ef48 selftest: Factor out smbtorture4testsuite_cmdarray()
       via  e4f399126e7 selftest: Assemble smbtorture arguments as a list
       via  536694d436f selftest: Remove an unnecessary space character
       via  ce3b594a22c selftest: Remove an obsolete knownfail entry
      from  959235fffb8 ctdb-docs: Move CTDB_SERVICE_NMB to new 48.netbios section

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit cb37caaa56ad9bac0df3092f64c9b0b08f4b3a9b
Author: Volker Lendecke <vl at samba.org>
Date:   Thu Feb 27 00:52:30 2020 -0800

    selftest: Run libsmbclient with and without unix extensions
    
    The libsmbclient readdir tests are broken just for the unix extension
    case. For example they assume our "map archive" behaviour. This will
    have to be parameterized once unix extensions become better
    implemented in libsmbclient
    
    Signed-off-by: Volker Lendecke <vl at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>
    
    Autobuild-User(master): Jeremy Allison <jra at samba.org>
    Autobuild-Date(master): Thu Feb 27 19:34:36 UTC 2020 on sn-devel-184

commit bb5cf6747624d11a2fcab19bf20322ca2acba007
Author: Volker Lendecke <vl at samba.org>
Date:   Wed Feb 26 15:27:02 2020 -0800

    selftest: Introduce planlibsmbclienttest()
    
    Small refactoring
    
    Signed-off-by: Volker Lendecke <vl at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit ac65874ef48f43507474d2b05030e2fc6afa180f
Author: Volker Lendecke <vl at samba.org>
Date:   Wed Feb 26 14:36:32 2020 -0800

    selftest: Factor out smbtorture4testsuite_cmdarray()
    
    This will be used in the libsmbclient tests soon
    
    Signed-off-by: Volker Lendecke <vl at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit e4f399126e72111b92fcdc5acc749d0ce96aaf46
Author: Volker Lendecke <vl at samba.org>
Date:   Wed Feb 26 14:07:54 2020 -0800

    selftest: Assemble smbtorture arguments as a list
    
    I'm planning to mess with libsmbclient tests calling into
    smbtorture4. For this it will be much more convenient to have the
    arguments available as a higher-level data structure than just a
    string.
    
    Checked by "diff" on the testlist before and after -- no change.
    
    Signed-off-by: Volker Lendecke <vl at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit 536694d436f3e4322ad77ebe33121d66a444bbec
Author: Volker Lendecke <vl at samba.org>
Date:   Wed Feb 26 14:07:09 2020 -0800

    selftest: Remove an unnecessary space character
    
    The pattern "//%s/%s %s" already provides the space. Why this patch? It makes
    checking the next patch trivial.
    
    Signed-off-by: Volker Lendecke <vl at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit ce3b594a22c913dc262957e68269af89bedab7ef
Author: Volker Lendecke <vl at samba.org>
Date:   Thu Feb 27 00:29:16 2020 -0800

    selftest: Remove an obsolete knownfail entry
    
    Since ae76d218346 this is not run anymore
    
    Signed-off-by: Volker Lendecke <vl at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

-----------------------------------------------------------------------

Summary of changes:
 selftest/knownfail                |  3 +--
 selftest/knownfail.d/libsmbclient |  4 ++--
 selftest/selftesthelpers.py       | 15 +++++++++++----
 source3/selftest/tests.py         |  2 +-
 source4/selftest/tests.py         | 26 ++++++++++++++++++++------
 5 files changed, 35 insertions(+), 15 deletions(-)


Changeset truncated at 500 lines:

diff --git a/selftest/knownfail b/selftest/knownfail
index c78c716beb2..79766000d2f 100644
--- a/selftest/knownfail
+++ b/selftest/knownfail
@@ -19,7 +19,6 @@
 ^samba3.nbt.dgram.*netlogon2\(nt4_dc\)
 ^samba3.*rap.sam.*.useradd # Not provided by Samba 3
 ^samba3.*rap.sam.*.userdelete # Not provided by Samba 3
-^samba3.libsmbclient.opendir # This requires a workgroup called 'WORKGROUP' and for netbios browse lists to have been registered
 # see bug 8412
 ^samba3.smb2.rename.*.simple_nodelete
 ^samba3.smb2.rename.*.no_share_delete_no_delete_access
@@ -141,7 +140,7 @@
 ^samba4.smb2.acls.*.ACCESSBASED
 ^samba4.ldap.dirsync.python.ad_dc_ntvfs..__main__.ExtendedDirsyncTests.test_dirsync_deleted_items
 #^samba4.ldap.dirsync.python.ad_dc_ntvfs..__main__.ExtendedDirsyncTests.*
-^samba4.libsmbclient.opendir.(NT1|SMB3).opendir # This requires netbios browsing
+^samba4.*libsmbclient.opendir.(NT1|SMB3).opendir # This requires netbios browsing
 ^samba4.rpc.drsuapi.*.drsuapi.DsGetDomainControllerInfo\(.*\)$
 ^samba4.smb2.oplock.exclusive2\(.*\)$ # samba 4 oplocks are a mess
 ^samba4.smb2.oplock.exclusive5\(.*\)$ # samba 4 oplocks are a mess
diff --git a/selftest/knownfail.d/libsmbclient b/selftest/knownfail.d/libsmbclient
index dddd6d24920..8d8ef3cbaa2 100644
--- a/selftest/knownfail.d/libsmbclient
+++ b/selftest/knownfail.d/libsmbclient
@@ -1,2 +1,2 @@
-samba4.libsmbclient.readdirplus2.NT1.readdirplus2.*
-samba4.libsmbclient.readdirplus_seek.NT1.readdirplus_seek.*
+samba4.unix_ext.libsmbclient.readdirplus2.NT1.readdirplus2.*
+samba4.unix_ext.libsmbclient.readdirplus_seek.NT1.readdirplus_seek.*
diff --git a/selftest/selftesthelpers.py b/selftest/selftesthelpers.py
index 1afabf3cdca..1fdb2e461e1 100644
--- a/selftest/selftesthelpers.py
+++ b/selftest/selftesthelpers.py
@@ -172,14 +172,21 @@ smbtorture4_options = [
     "--format=subunit"
 ] + get_env_torture_options()
 
+def smbtorture4testsuite_cmdarray(name, env, options, target):
+    cmdarray = [ valgrindify(smbtorture4), "$LISTOPT", "$LOADLIST" ]
+    cmdarray += smbtorture4_options
+    cmdarray += [ "--target=%s" % target ]
+    cmdarray += options
+    cmdarray += [ name ]
+    return cmdarray
 
 def plansmbtorture4testsuite(name, env, options, target, modname=None):
     if modname is None:
         modname = "samba4.%s" % name
-    if isinstance(options, list):
-        options = " ".join(options)
-    options = " ".join(smbtorture4_options + ["--target=%s" % target]) + " " + options
-    cmdline = "%s $LISTOPT $LOADLIST %s %s" % (valgrindify(smbtorture4), options, name)
+    if isinstance(options, str):
+        options = options.split()
+    cmdarray = smbtorture4testsuite_cmdarray(name, env, options, target)
+    cmdline = " ".join(cmdarray)
     plantestsuite_loadlist(modname, env, cmdline)
 
 
diff --git a/source3/selftest/tests.py b/source3/selftest/tests.py
index 041bcf94e03..ba110c1d161 100755
--- a/source3/selftest/tests.py
+++ b/source3/selftest/tests.py
@@ -171,7 +171,7 @@ shares = [
 for s in shares:
     plantestsuite("samba3.smbtorture_s3.%s(simpleserver).SMB2-BASIC" % s, "simpleserver", [os.path.join(samba3srcdir, "script/tests/test_smbtorture_s3.sh"), 'SMB2-BASIC', '//$SERVER_IP/' + s, '$USERNAME', '$PASSWORD', smbtorture3, "", "-l $LOCAL_PATH"])
     t = "smb2.compound_find"
-    plansmbtorture4testsuite(t, "simpleserver", "//%s/%s %s" % ('$SERVER_IP', s, ' -U$USERNAME%$PASSWORD'), description=s)
+    plansmbtorture4testsuite(t, "simpleserver", "//%s/%s %s" % ('$SERVER_IP', s, '-U$USERNAME%$PASSWORD'), description=s)
 
 posix_tests = ["POSIX", "POSIX-APPEND", "POSIX-SYMLINK-ACL", "POSIX-SYMLINK-EA", "POSIX-OFD-LOCK",
                "POSIX-STREAM-DELETE", "WINDOWS-BAD-SYMLINK", "POSIX-MKDIR",
diff --git a/source4/selftest/tests.py b/source4/selftest/tests.py
index 389a142db7d..5796f828bdd 100755
--- a/source4/selftest/tests.py
+++ b/source4/selftest/tests.py
@@ -365,6 +365,25 @@ netapi = smbtorture4_testsuites("netapi.")
 for t in base + raw + smb2 + netapi:
     plansmbtorture4testsuite(t, "ad_dc_ntvfs", ['//$SERVER/tmp', '-U$USERNAME%$PASSWORD'] + ntvfsargs)
 
+def planlibsmbclienttest(name, testargs, proto):
+    env = "nt4_dc"
+    cmdarray = selftesthelpers.smbtorture4testsuite_cmdarray(
+        name,
+        env,
+        testargs + [ "--option=torture:clientprotocol=%s" % proto],
+        'samba4')
+    plantestsuite_loadlist(
+        "samba4.unix_ext.%s.%s" % (t, proto), env, " ".join(cmdarray))
+
+    plantestsuite_loadlist(
+        "samba4.non_unix_ext.%s.%s" % (t, proto),
+        env,
+        "(inject=\"${SERVERCONFFILE%/*}/global_inject.conf\"; " +
+        "echo \"unix extensions = no\" > ${inject} ; " +
+        " ".join(cmdarray) +
+        "; > ${inject})")
+
+
 libsmbclient = smbtorture4_testsuites("libsmbclient.")
 protocols = [ 'NT1', 'SMB3' ]
 for t in libsmbclient:
@@ -381,12 +400,7 @@ for t in libsmbclient:
         ]
 
     for proto in protocols:
-        plansmbtorture4testsuite(
-            t,
-            "nt4_dc",
-            libsmbclient_testargs +
-            [ "--option=torture:clientprotocol=%s" % proto],
-            "samba4.%s.%s" % (t, proto))
+        planlibsmbclienttest(t, libsmbclient_testargs, proto)
 
 plansmbtorture4testsuite("raw.qfileinfo.ipc", "ad_dc_ntvfs", '//$SERVER/ipc\$ -U$USERNAME%$PASSWORD')
 


-- 
Samba Shared Repository



More information about the samba-cvs mailing list