From: Tim Beale Date: Thu, 22 Nov 2018 01:05:01 +0000 (+1300) Subject: tests: Run backup tests against restoredc (SMBv1 disabled) X-Git-Tag: tdb-1.3.17~635 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=738418ea3ee669b1b917f4b8a6da1f69fa3558f1;p=thirdparty%2Fsamba.git tests: Run backup tests against restoredc (SMBv1 disabled) Running the backup tests against the restoredc highlights that the backup online/rename commands don't work if SMBv1 is disabled. Note that the offline commands still work because they don't rely on an SMB connection to the server. (Note that running the backup tests against the restoredc is probably a good idea anyway, to prove that there's no limit to the number of times you can restore a domain from backup, i.e. we support more than just a one-off restore). BUG: https://bugzilla.samba.org/show_bug.cgi?id=13676 Signed-off-by: Tim Beale Reviewed-by: Andrew Bartlett --- diff --git a/selftest/knownfail.d/domain_backup b/selftest/knownfail.d/domain_backup new file mode 100644 index 00000000000..24f4d87981c --- /dev/null +++ b/selftest/knownfail.d/domain_backup @@ -0,0 +1,12 @@ +# these tests only work with SMBv1, which is disabled on the restoredc +samba.tests.domain_backup.samba.tests.domain_backup.DomainBackupRename.test_one_way_links\(restoredc:local\) +samba.tests.domain_backup.samba.tests.domain_backup.DomainBackupRename.test_backup_untar\(restoredc:local\) +samba.tests.domain_backup.samba.tests.domain_backup.DomainBackupRename.test_backup_restore_with_conf\(restoredc:local\) +samba.tests.domain_backup.samba.tests.domain_backup.DomainBackupRename.test_backup_restore_no_secrets\(restoredc:local\) +samba.tests.domain_backup.samba.tests.domain_backup.DomainBackupRename.test_backup_restore_into_site\(restoredc:local\) +samba.tests.domain_backup.samba.tests.domain_backup.DomainBackupRename.test_backup_restore\(restoredc:local\) +samba.tests.domain_backup.samba.tests.domain_backup.DomainBackupOnline.test_backup_untar\(restoredc:local\) +samba.tests.domain_backup.samba.tests.domain_backup.DomainBackupOnline.test_backup_restore_with_conf\(restoredc:local\) +samba.tests.domain_backup.samba.tests.domain_backup.DomainBackupOnline.test_backup_restore_no_secrets\(restoredc:local\) +samba.tests.domain_backup.samba.tests.domain_backup.DomainBackupOnline.test_backup_restore_into_site\(restoredc:local\) +samba.tests.domain_backup.samba.tests.domain_backup.DomainBackupOnline.test_backup_restore\(restoredc:local\) diff --git a/source4/selftest/tests.py b/source4/selftest/tests.py index 37b7a04c1fb..dc5807247ab 100755 --- a/source4/selftest/tests.py +++ b/source4/selftest/tests.py @@ -53,6 +53,9 @@ smbclient4 = binpath('smbclient4') bbdir = os.path.join(srcdir(), "testprogs/blackbox") +# alias to highlight what tests we want to run against a DC with SMBv1 disabled +smbv1_disabled_testenv = "restoredc" + # Simple tests for LDAP and CLDAP for auth_type in ['', '-k no', '-k yes']: for auth_level in ['--option=clientldapsaslwrapping=plain', '--sign', '--encrypt']: @@ -779,9 +782,11 @@ planoldpythontestsuite("fl2003dc:local", planoldpythontestsuite("ad_dc", "samba.tests.password_hash_ldap", extra_args=['-U"$USERNAME%$PASSWORD"'], py3_compatible=True) -planoldpythontestsuite("ad_dc:local", - "samba.tests.domain_backup", - extra_args=['-U"$USERNAME%$PASSWORD"']) + +for env in ["ad_dc", smbv1_disabled_testenv]: + planoldpythontestsuite(env + ":local", "samba.tests.domain_backup", + extra_args=['-U"$USERNAME%$PASSWORD"']) + planoldpythontestsuite("none", "samba.tests.domain_backup_offline") # Encrypted secrets