[SCM] Samba Shared Repository - branch master updated
Jelmer Vernooij
jelmer at samba.org
Thu Nov 4 06:14:01 MDT 2010
The branch, master has been updated
via c4dab7d urgent_replication: forbid empty subunit output.
via b6cef24 selftest: Allow some tests to output empty subunit data.
via 28f1228 s4-dsdb Fix urgent_replication test not to set an invalid userAccountControl
via fea02db urgent_replication: Fix syntax error.
from 81e5321 s4-dsdb: use LDB_FLAG_MOD_REPLACE for isDeleted
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit c4dab7d545d35a90761fcd8b1cb6f2959ae342ab
Author: Jelmer Vernooij <jelmer at samba.org>
Date: Thu Nov 4 12:29:42 2010 +0100
urgent_replication: forbid empty subunit output.
Autobuild-User: Jelmer Vernooij <jelmer at samba.org>
Autobuild-Date: Thu Nov 4 12:13:47 UTC 2010 on sn-devel-104
commit b6cef24463def4b6d52636f2b026abcd6e563d3c
Author: Jelmer Vernooij <jelmer at samba.org>
Date: Thu Nov 4 02:07:57 2010 +0100
selftest: Allow some tests to output empty subunit data.
commit 28f1228b01056dc6eefc64a24fe317d68e170195
Author: Andrew Bartlett <abartlet at samba.org>
Date: Thu Nov 4 13:16:11 2010 +1100
s4-dsdb Fix urgent_replication test not to set an invalid userAccountControl
A userAccountControl value of 0 or 1 is invalid, you must include one of
the account types.
Andrew Bartlett
commit fea02db10f672635bc08b80c32bbd296b0d4fc9d
Author: Jelmer Vernooij <jelmer at samba.org>
Date: Thu Nov 4 01:36:57 2010 +0100
urgent_replication: Fix syntax error.
-----------------------------------------------------------------------
Summary of changes:
source4/dsdb/tests/python/urgent_replication.py | 7 ++++---
source4/selftest/tests.py | 17 +++++++++++------
2 files changed, 15 insertions(+), 9 deletions(-)
Changeset truncated at 500 lines:
diff --git a/source4/dsdb/tests/python/urgent_replication.py b/source4/dsdb/tests/python/urgent_replication.py
index 7f0956e..be0b0b0 100755
--- a/source4/dsdb/tests/python/urgent_replication.py
+++ b/source4/dsdb/tests/python/urgent_replication.py
@@ -17,6 +17,7 @@ from ldb import (SCOPE_BASE, LdbError, ERR_NO_SUCH_OBJECT, Message,
MessageElement, Dn, FLAG_MOD_REPLACE)
from samba.samdb import SamDB
import samba.tests
+import samba.dsdb as dsdb
from subunit.run import SubunitTestRunner
import unittest
@@ -139,7 +140,7 @@ systemFlags: 33554432""", ["relax:0"])
"nCName": self.base_dn,
"showInAdvancedViewOnly": "TRUE",
"name": "test crossRef",
- "systemFlags": "1", ["relax:0"]})
+ "systemFlags": "1"}, ["relax:0"])
# urgent replication should be enabled when creating
res = self.ldb.load_partition_usn("cn=Configuration," + self.base_dn)
@@ -315,7 +316,7 @@ rIDAvailablePool: 133001-1073741823""", ["relax:0"])
"dn": "cn=user UrgAttr test,cn=users," + self.base_dn,
"objectclass":"user",
"samaccountname":"user UrgAttr test",
- "userAccountControl":"1",
+ "userAccountControl":str(dsdb.UF_NORMAL_ACCOUNT),
"lockoutTime":"0",
"pwdLastSet":"0",
"description":"urgent attributes test description"})
@@ -327,7 +328,7 @@ rIDAvailablePool: 133001-1073741823""", ["relax:0"])
# urgent replication should be enabled when modifying userAccountControl
m = Message()
m.dn = Dn(ldb, "cn=user UrgAttr test,cn=users," + self.base_dn)
- m["userAccountControl"] = MessageElement("0", FLAG_MOD_REPLACE,
+ m["userAccountControl"] = MessageElement(str(dsdb.UF_NORMAL_ACCOUNT+dsdb.UF_SMARTCARD_REQUIRED), FLAG_MOD_REPLACE,
"userAccountControl")
ldb.modify(m)
res = self.ldb.load_partition_usn(self.base_dn)
diff --git a/source4/selftest/tests.py b/source4/selftest/tests.py
index 16a1059..89fcbd6 100755
--- a/source4/selftest/tests.py
+++ b/source4/selftest/tests.py
@@ -48,7 +48,7 @@ def valgrindify(cmdline):
return valgrind + " " + cmdline
-def plantestsuite(name, env, cmdline):
+def plantestsuite(name, env, cmdline, allow_empty_output=False):
"""Plan a test suite.
:param name: Testsuite name
@@ -60,7 +60,12 @@ def plantestsuite(name, env, cmdline):
print env
if isinstance(cmdline, list):
cmdline = " ".join(cmdline)
- print "%s 2>&1 | ../selftest/filter-subunit --prefix=\"%s.\"" % (cmdline, name)
+ filter_subunit_args = []
+ if not allow_empty_output:
+ filter_subunit_args.append("--fail-on-empty")
+ print "%s 2>&1 | ../selftest/filter-subunit %s --prefix=\"%s.\"" % (cmdline, " ".join(filter_subunit_args), name)
+ if allow_empty_output:
+ print "WARNING: allowing empty subunit output from %s" % name
def plantestsuite_loadlist(name, env, cmdline):
@@ -73,7 +78,7 @@ def plantestsuite_loadlist(name, env, cmdline):
print env
if isinstance(cmdline, list):
cmdline = " ".join(cmdline)
- print "%s $LOADLIST 2>&1 | ../selftest/filter-subunit --prefix=\"%s.\"" % (cmdline, fullname)
+ print "%s $LOADLIST 2>&1 | ../selftest/filter-subunit --fail-on-empty --prefix=\"%s.\"" % (cmdline, fullname)
def plantestsuite_idlist(name, env, cmdline):
@@ -192,7 +197,7 @@ for t in smb4torture_testsuites("LDAP-"):
ldbdir = os.path.join(samba4srcdir, "lib/ldb")
# Don't run LDB tests when using system ldb, as we won't have ldbtest installed
if os.path.exists(os.path.join(samba4bindir, "ldbtest")):
- plantestsuite("ldb.base", "none", "TEST_DATA_PREFIX=$PREFIX %s/tests/test-tdb.sh" % ldbdir)
+ plantestsuite("ldb.base", "none", "TEST_DATA_PREFIX=$PREFIX %s/tests/test-tdb.sh" % ldbdir, allow_empty_output=True)
else:
skiptestsuite("ldb.base", "Using system LDB, ldbtest not available")
@@ -487,8 +492,8 @@ planpythontestsuite("none", "samba.tests.xattr")
planpythontestsuite("none", "samba.tests.ntacls")
plantestsuite("samba4.deletetest.python(dc)", "dc", ['PYTHONPATH="$PYTHONPATH:../lib/subunit/python:../lib/testtools"', python, os.path.join(samba4srcdir, "dsdb/tests/python/deletetest.py"), '$SERVER', '-U"$USERNAME%$PASSWORD"', '-W', '$DOMAIN'])
plantestsuite("samba4.policy.python", "none", ['PYTHONPATH="$PYTHONPATH:lib/policy/tests/python"', subunitrun, 'bindings'])
-plantestsuite("samba4.blackbox.samba3dump", "none", [python, os.path.join(samba4srcdir, "scripting/bin/samba3dump"), os.path.join(samba4srcdir, "../testdata/samba3")])
-plantestsuite("samba4.blackbox.upgrade", "none", ["rm -rf $PREFIX/upgrade;", python, os.path.join(samba4srcdir, "setup/upgrade_from_s3"), "--targetdir=$PREFIX/upgrade", os.path.normpath(os.path.join(samba4srcdir, "../testdata/samba3")), os.path.normpath(os.path.join(samba4srcdir, "../testdata/samba3/smb.conf"))])
+plantestsuite("samba4.blackbox.samba3dump", "none", [python, os.path.join(samba4srcdir, "scripting/bin/samba3dump"), os.path.join(samba4srcdir, "../testdata/samba3")], allow_empty_output=True)
+plantestsuite("samba4.blackbox.upgrade", "none", ["rm -rf $PREFIX/upgrade;", python, os.path.join(samba4srcdir, "setup/upgrade_from_s3"), "--targetdir=$PREFIX/upgrade", os.path.normpath(os.path.join(samba4srcdir, "../testdata/samba3")), os.path.normpath(os.path.join(samba4srcdir, "../testdata/samba3/smb.conf"))], allow_empty_output=True)
plantestsuite("samba4.blackbox.provision.py", "none", ["PYTHON=%s" % python, os.path.join(samba4srcdir, "setup/tests/blackbox_provision.sh"), '$PREFIX/provision'])
plantestsuite("samba4.blackbox.upgradeprovision.py", "none", ["PYTHON=%s" % python, os.path.join(samba4srcdir, "setup/tests/blackbox_upgradeprovision.sh"), '$PREFIX/provision'])
plantestsuite("samba4.blackbox.setpassword.py", "none", ["PYTHON=%s" % python, os.path.join(samba4srcdir, "setup/tests/blackbox_setpassword.sh"), '$PREFIX/provision'])
--
Samba Shared Repository
More information about the samba-cvs
mailing list