summaryrefslogtreecommitdiff
path: root/source4/dsdb
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2012-06-19 12:43:08 +0200
committerJelmer Vernooij <jelmer@samba.org>2012-06-21 18:05:33 +0200
commitcbd660d01381465a35dc696b6a135de22f7682e6 (patch)
tree9ab54901865002a4c36735accb0e04def259af2e /source4/dsdb
parent3c74117e2eb6616b8f539807ae8824d963f7987c (diff)
downloadsamba-cbd660d01381465a35dc696b6a135de22f7682e6.tar.gz
samba-cbd660d01381465a35dc696b6a135de22f7682e6.tar.bz2
samba-cbd660d01381465a35dc696b6a135de22f7682e6.zip
samdb: Accept a list of member variables rather than a comma-separated string.
Diffstat (limited to 'source4/dsdb')
-rwxr-xr-xsource4/dsdb/tests/python/acl.py8
-rwxr-xr-xsource4/dsdb/tests/python/dirsync.py18
-rwxr-xr-xsource4/dsdb/tests/python/sec_descriptor.py8
3 files changed, 17 insertions, 17 deletions
diff --git a/source4/dsdb/tests/python/acl.py b/source4/dsdb/tests/python/acl.py
index a62461449d..bbd4343a21 100755
--- a/source4/dsdb/tests/python/acl.py
+++ b/source4/dsdb/tests/python/acl.py
@@ -128,9 +128,9 @@ class AclAddTests(AclTests):
self.ldb_admin.newuser(self.regular_user, self.user_pass)
# add admins to the Domain Admins group
- self.ldb_admin.add_remove_group_members("Domain Admins", self.usr_admin_owner,
+ self.ldb_admin.add_remove_group_members("Domain Admins", [self.usr_admin_owner],
add_members_operation=True)
- self.ldb_admin.add_remove_group_members("Domain Admins", self.usr_admin_not_owner,
+ self.ldb_admin.add_remove_group_members("Domain Admins", [self.usr_admin_not_owner],
add_members_operation=True)
self.ldb_owner = self.get_ldb_connection(self.usr_admin_owner, self.user_pass)
@@ -613,7 +613,7 @@ class AclSearchTests(AclTests):
self.ldb_admin.newuser(self.u2, self.user_pass)
self.ldb_admin.newuser(self.u3, self.user_pass)
self.ldb_admin.newgroup(self.group1, grouptype=samba.dsdb.GTYPE_SECURITY_GLOBAL_GROUP)
- self.ldb_admin.add_remove_group_members(self.group1, self.u2,
+ self.ldb_admin.add_remove_group_members(self.group1, [self.u2],
add_members_operation=True)
self.ldb_user = self.get_ldb_connection(self.u1, self.user_pass)
self.ldb_user2 = self.get_ldb_connection(self.u2, self.user_pass)
@@ -1521,7 +1521,7 @@ class AclExtendedTests(AclTests):
self.ldb_admin.newuser(self.u1, self.user_pass)
self.ldb_admin.newuser(self.u2, self.user_pass)
self.ldb_admin.newuser(self.u3, self.user_pass)
- self.ldb_admin.add_remove_group_members("Domain Admins", self.u3,
+ self.ldb_admin.add_remove_group_members("Domain Admins", [self.u3],
add_members_operation=True)
self.ldb_user1 = self.get_ldb_connection(self.u1, self.user_pass)
self.ldb_user2 = self.get_ldb_connection(self.u2, self.user_pass)
diff --git a/source4/dsdb/tests/python/dirsync.py b/source4/dsdb/tests/python/dirsync.py
index d6a21a9544..f36a3c0d2c 100755
--- a/source4/dsdb/tests/python/dirsync.py
+++ b/source4/dsdb/tests/python/dirsync.py
@@ -124,7 +124,7 @@ class SimpleDirsyncTests(DirsyncBaseTests):
self.sd_utils.dacl_add_ace(self.base_dn, mod)
# add admins to the Domain Admins group
- self.ldb_admin.add_remove_group_members("Domain Admins", self.admin_user,
+ self.ldb_admin.add_remove_group_members("Domain Admins", [self.admin_user],
add_members_operation=True)
def tearDown(self):
@@ -477,7 +477,7 @@ class SimpleDirsyncTests(DirsyncBaseTests):
ctl[2] = "1"
ctl[3] = "10000"
control1 = str(":".join(ctl))
- self.ldb_admin.add_remove_group_members("Administrators", self.simple_user,
+ self.ldb_admin.add_remove_group_members("Administrators", [self.simple_user],
add_members_operation=True)
res = self.ldb_simple.search(self.base_dn,
@@ -492,7 +492,7 @@ class SimpleDirsyncTests(DirsyncBaseTests):
control1 = str(":".join(ctl))
# remove the user from the group
- self.ldb_admin.add_remove_group_members("Administrators", self.simple_user,
+ self.ldb_admin.add_remove_group_members("Administrators", [self.simple_user],
add_members_operation=False)
res = self.ldb_simple.search(self.base_dn,
@@ -502,7 +502,7 @@ class SimpleDirsyncTests(DirsyncBaseTests):
self.assertEqual(len(res[0].get("member")), size )
self.ldb_admin.newgroup("testgroup")
- self.ldb_admin.add_remove_group_members("testgroup", self.simple_user,
+ self.ldb_admin.add_remove_group_members("testgroup", [self.simple_user],
add_members_operation=True)
res = self.ldb_admin.search(self.base_dn,
@@ -532,7 +532,7 @@ class SimpleDirsyncTests(DirsyncBaseTests):
ctl[3] = "10000"
control1 = str(":".join(ctl))
- self.ldb_admin.add_remove_group_members("testgroup", self.simple_user,
+ self.ldb_admin.add_remove_group_members("testgroup", [self.simple_user],
add_members_operation=False)
res = self.ldb_admin.search(self.base_dn,
@@ -608,9 +608,9 @@ class ExtendedDirsyncTests(SimpleDirsyncTests):
ctl[2] = "%d" % flag_incr_linked
ctl[3] = "10000"
control1 = str(":".join(ctl))
- self.ldb_admin.add_remove_group_members("Administrators", self.simple_user,
+ self.ldb_admin.add_remove_group_members("Administrators", [self.simple_user],
add_members_operation=True)
- self.ldb_admin.add_remove_group_members("Administrators", self.dirsync_user,
+ self.ldb_admin.add_remove_group_members("Administrators", [self.dirsync_user],
add_members_operation=True)
@@ -626,7 +626,7 @@ class ExtendedDirsyncTests(SimpleDirsyncTests):
control1 = str(":".join(ctl))
# remove the user from the group
- self.ldb_admin.add_remove_group_members("Administrators", self.simple_user,
+ self.ldb_admin.add_remove_group_members("Administrators", [self.simple_user],
add_members_operation=False)
res = self.ldb_admin.search(self.base_dn,
@@ -642,7 +642,7 @@ class ExtendedDirsyncTests(SimpleDirsyncTests):
ctl[3] = "10000"
control2 = str(":".join(ctl))
- self.ldb_admin.add_remove_group_members("Administrators", self.dirsync_user,
+ self.ldb_admin.add_remove_group_members("Administrators", [self.dirsync_user],
add_members_operation=False)
res = self.ldb_admin.search(self.base_dn,
diff --git a/source4/dsdb/tests/python/sec_descriptor.py b/source4/dsdb/tests/python/sec_descriptor.py
index 80212a1b5c..087ce5e2cb 100755
--- a/source4/dsdb/tests/python/sec_descriptor.py
+++ b/source4/dsdb/tests/python/sec_descriptor.py
@@ -200,13 +200,13 @@ class OwnerGroupDescriptorTests(DescriptorTests):
self.ldb_admin.newuser("testuser8", "samba123@")
self.ldb_admin.add_remove_group_members("Enterprise Admins",
- "testuser1,testuser5,testuser6,testuser8",
+ ["testuser1", "testuser5", "testuser6", "testuser8"],
add_members_operation=True)
self.ldb_admin.add_remove_group_members("Domain Admins",
- "testuser2,testuser5,testuser6,testuser7",
+ ["testuser2","testuser5","testuser6","testuser7"],
add_members_operation=True)
self.ldb_admin.add_remove_group_members("Schema Admins",
- "testuser3,testuser6,testuser7,testuser8",
+ ["testuser3","testuser6","testuser7","testuser8"],
add_members_operation=True)
self.results = {
@@ -1865,7 +1865,7 @@ class RightsAttributesTests(DescriptorTests):
# User 2, Domain Admins
self.ldb_admin.newuser("testuser_attr2", "samba123@")
self.ldb_admin.add_remove_group_members("Domain Admins",
- "testuser_attr2",
+ ["testuser_attr2"],
add_members_operation=True)
def test_sDRightsEffective(self):