summaryrefslogtreecommitdiff
path: root/source4/lib/ldb/tests/python
diff options
context:
space:
mode:
authorMatthias Dieter Wallnöfer <mdw@samba.org>2010-06-10 16:18:41 +0200
committerMatthias Dieter Wallnöfer <mdw@samba.org>2010-06-10 16:22:09 +0200
commitbdd83c0639ad0066a2b0e77611548f2d165bb747 (patch)
treecc37f4f2c3a3bd915dea5c8d87803dc72cf56962 /source4/lib/ldb/tests/python
parentd604d499390dea1a10bfdd462b512bfe1845a101 (diff)
downloadsamba-bdd83c0639ad0066a2b0e77611548f2d165bb747.tar.gz
samba-bdd83c0639ad0066a2b0e77611548f2d165bb747.tar.bz2
samba-bdd83c0639ad0066a2b0e77611548f2d165bb747.zip
s4:ldap.py - add testcase which demonstrates the reset of the "primaryGroupID"
Diffstat (limited to 'source4/lib/ldb/tests/python')
-rwxr-xr-xsource4/lib/ldb/tests/python/ldap.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/source4/lib/ldb/tests/python/ldap.py b/source4/lib/ldb/tests/python/ldap.py
index 9682b4bc53..db69b47ab3 100755
--- a/source4/lib/ldb/tests/python/ldap.py
+++ b/source4/lib/ldb/tests/python/ldap.py
@@ -1028,6 +1028,13 @@ objectClass: container
"dn": "cn=ldaptestuser,cn=users," + self.base_dn,
"objectclass": ["user", "person"]})
+ # We should be able to reset our actual primary group
+ m = Message()
+ m.dn = Dn(ldb, "cn=ldaptestuser,cn=users," + self.base_dn)
+ m["primaryGroupID"] = MessageElement("513", FLAG_MOD_REPLACE,
+ "primaryGroupID")
+ ldb.modify(m)
+
# Try to add invalid primary group
m = Message()
m.dn = Dn(ldb, "cn=ldaptestuser,cn=users," + self.base_dn)