]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
selftest: Run smbtorture3 SHORTNAME-TEST without unix extensions
authorVolker Lendecke <vl@samba.org>
Mon, 2 Mar 2020 20:34:37 +0000 (21:34 +0100)
committerJeremy Allison <jra@samba.org>
Tue, 3 Mar 2020 17:48:37 +0000 (17:48 +0000)
Soon cli_list() will change to SMB_FIND_FILE_UNIX_INFO2 which does not
provide a shortname. For now we lose that as an encrypted test, as for
now it's a SMB1 test which requires unix extensions for
encryption. Hopefully we don't forget to reenable this once the test
is converted to SMB2

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
nonunix

source3/script/tests/test_smbtorture_s3_no_unix_ext.sh [new file with mode: 0755]
source3/selftest/tests.py

diff --git a/source3/script/tests/test_smbtorture_s3_no_unix_ext.sh b/source3/script/tests/test_smbtorture_s3_no_unix_ext.sh
new file mode 100755 (executable)
index 0000000..19af4ff
--- /dev/null
@@ -0,0 +1,14 @@
+#!/bin/bash
+# this runs test_smbtorture_s3 with disabled unix extensions
+
+if [ -z "$SERVERCONFFILE" ] ; then
+    echo \$SERVERCONFFILE not defined
+    exit 1
+fi
+inject=${SERVERCONFFILE%/*}/global_inject.conf
+
+echo "unix extensions = no" > ${inject}
+$(dirname $0)/test_smbtorture_s3.sh $*
+ret=$?
+> ${inject}
+exit $ret
index ba110c1d16165663f9e5c71ea994d70386c2ed30..6e9d3ddb144d6bcd744fc7a2956d47dc9e28b8e8 100755 (executable)
@@ -90,7 +90,7 @@ tests = ["FDPASS", "LOCK1", "LOCK2", "LOCK3", "LOCK4", "LOCK5", "LOCK6", "LOCK7"
          "OPEN", "XCOPY", "RENAME", "DELETE", "DELETE-LN", "WILDDELETE", "PROPERTIES", "W2K",
          "TCON2", "IOCTL", "CHKPATH", "FDSESS", "CHAIN1", "CHAIN2", "OWNER-RIGHTS",
          "CHAIN3", "PIDHIGH", "CLI_SPLICE",
-         "UID-REGRESSION-TEST", "SHORTNAME-TEST",
+         "UID-REGRESSION-TEST",
          "CASE-INSENSITIVE-CREATE", "SMB2-BASIC", "NTTRANS-FSCTL", "SMB2-NEGPROT",
          "SMB2-SESSION-REAUTH", "SMB2-SESSION-RECONNECT", "SMB2-FTRUNCATE",
          "SMB2-ANONYMOUS", "SMB2-DIR-FSYNC",
@@ -113,6 +113,26 @@ for t in tests:
         plantestsuite("samba3.smbtorture_s3.plain.%s" % t, "fileserver", [os.path.join(samba3srcdir, "script/tests/test_smbtorture_s3.sh"), t, '//$SERVER_IP/tmp', '$USERNAME', '$PASSWORD', smbtorture3, "", "-l $LOCAL_PATH", "-mNT1"])
     plantestsuite("samba3.smbtorture_s3.plain.%s" % t, "ad_dc_ntvfs", [os.path.join(samba3srcdir, "script/tests/test_smbtorture_s3.sh"), t, '//$SERVER_IP/tmp', '$USERNAME', '$PASSWORD', smbtorture3, "", "-l $LOCAL_PATH"])
 
+nonunix_tests = [
+    "SHORTNAME-TEST"
+    ]
+
+for t in nonunix_tests:
+    plantestsuite(
+        "samba3.smbtorture_s3.plain.%s" % t,
+        "fileserver",
+        [os.path.join(samba3srcdir,
+                      "script/tests/test_smbtorture_s3_no_unix_ext.sh"),
+         t,
+         '//$SERVER_IP/tmp',
+         '$USERNAME',
+         '$PASSWORD',
+         smbtorture3,
+         "",
+         "-l $LOCAL_PATH"])
+    # Can't run SMB1 encrypted tests without unix extensions. This
+    # will have to be added once we do SMB3 unix extensions.
+
 t = "TLDAP"
 plantestsuite("samba3.smbtorture_s3.plain.%s" % t, "ad_dc", [os.path.join(samba3srcdir, "script/tests/test_smbtorture_s3.sh"), t, '//$SERVER/tmp', '$DC_USERNAME', '$DC_PASSWORD', smbtorture3, "", "-l $LOCAL_PATH"])