[SCM] Samba Shared Repository - branch master updated
Nadezhda Ivanova
nivanova at samba.org
Thu Nov 18 05:53:01 MST 2010
The branch, master has been updated
via 47784a1 s4-tests: Descriptor tests should use the existing samdb domain_dn method instead of defining a new one
via 763165c s4-tests: Acl tests should use the existing samdb domain_dn method instead of defining a new one
from 56512fb ldb:skel.c - don't introduce trailing whitespaces by a module template
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit 47784a14708827a0272b638c6ab088d74b392908
Author: Nadezhda Ivanova <nivanova at samba.org>
Date: Thu Nov 18 13:17:00 2010 +0200
s4-tests: Descriptor tests should use the existing samdb domain_dn method instead of defining a new one
Autobuild-User: Nadezhda Ivanova <nivanova at samba.org>
Autobuild-Date: Thu Nov 18 12:52:48 UTC 2010 on sn-devel-104
commit 763165c7bcff5d4b2c331a75869a7db82f5ec91a
Author: Nadezhda Ivanova <nivanova at samba.org>
Date: Thu Nov 18 13:13:35 2010 +0200
s4-tests: Acl tests should use the existing samdb domain_dn method instead of defining a new one
-----------------------------------------------------------------------
Summary of changes:
source4/dsdb/tests/python/acl.py | 8 +-------
source4/dsdb/tests/python/sec_descriptor.py | 8 +-------
2 files changed, 2 insertions(+), 14 deletions(-)
Changeset truncated at 500 lines:
diff --git a/source4/dsdb/tests/python/acl.py b/source4/dsdb/tests/python/acl.py
index 1726c43..b448d65 100755
--- a/source4/dsdb/tests/python/acl.py
+++ b/source4/dsdb/tests/python/acl.py
@@ -64,12 +64,6 @@ class AclTests(samba.tests.TestCase):
except LdbError, (num, _):
self.assertEquals(num, ERR_NO_SUCH_OBJECT)
- def find_basedn(self, ldb):
- res = ldb.search(base="", expression="", scope=SCOPE_BASE,
- attrs=["defaultNamingContext"])
- self.assertEquals(len(res), 1)
- return res[0]["defaultNamingContext"][0]
-
def find_domain_sid(self, ldb):
res = ldb.search(base=self.base_dn, expression="(objectClass=*)", scope=SCOPE_BASE)
return ndr_unpack(security.dom_sid,res[0]["objectSid"][0])
@@ -77,7 +71,7 @@ class AclTests(samba.tests.TestCase):
def setUp(self):
super(AclTests, self).setUp()
self.ldb_admin = ldb
- self.base_dn = self.find_basedn(self.ldb_admin)
+ self.base_dn = ldb.domain_dn()
self.domain_sid = self.find_domain_sid(self.ldb_admin)
self.user_pass = "samba123@"
res = self.ldb_admin.search(base="", expression="", scope=SCOPE_BASE,
diff --git a/source4/dsdb/tests/python/sec_descriptor.py b/source4/dsdb/tests/python/sec_descriptor.py
index 557d907..5b3bb6a 100755
--- a/source4/dsdb/tests/python/sec_descriptor.py
+++ b/source4/dsdb/tests/python/sec_descriptor.py
@@ -65,12 +65,6 @@ class DescriptorTests(samba.tests.TestCase):
except LdbError, (num, _):
self.assertEquals(num, ERR_NO_SUCH_OBJECT)
- def find_basedn(self, ldb):
- res = ldb.search(base="", expression="", scope=SCOPE_BASE,
- attrs=["defaultNamingContext"])
- self.assertEquals(len(res), 1)
- return res[0]["defaultNamingContext"][0]
-
def find_configurationdn(self, ldb):
res = ldb.search(base="", expression="", scope=SCOPE_BASE, attrs=["configurationNamingContext"])
self.assertEquals(len(res), 1)
@@ -276,7 +270,7 @@ member: """ + self.get_users_domain_dn(username)
def setUp(self):
super(DescriptorTests, self).setUp()
self.ldb_admin = ldb
- self.base_dn = self.find_basedn(self.ldb_admin)
+ self.base_dn = ldb.domain_dn()
self.configuration_dn = self.find_configurationdn(self.ldb_admin)
self.schema_dn = self.find_schemadn(self.ldb_admin)
self.domain_sid = self.find_domain_sid(self.ldb_admin)
--
Samba Shared Repository
More information about the samba-cvs
mailing list