mirror of
https://github.com/samba-team/samba.git
synced 2025-01-11 05:18:09 +03:00
ldb tests: api ensure database correctly populated
Signed-off-by: Gary Lockyer <gary@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
parent
25e1cfad3a
commit
9ca34b9c4a
@ -1221,6 +1221,19 @@ class AddModifyTests(LdbBaseTest):
|
||||
"name": b"Admins",
|
||||
"x": "z", "y": "a",
|
||||
"objectUUID": b"0123456789abcde2"})
|
||||
|
||||
res2 = self.l.search(base="DC=SAMBA,DC=ORG",
|
||||
scope=ldb.SCOPE_SUBTREE,
|
||||
expression="(objectUUID=0123456789abcde1)")
|
||||
self.assertEqual(len(res2), 1)
|
||||
self.assertEqual(str(res2[0].dn), "OU=DUP,DC=SAMBA,DC=ORG")
|
||||
|
||||
res3 = self.l.search(base="DC=SAMBA,DC=ORG",
|
||||
scope=ldb.SCOPE_SUBTREE,
|
||||
expression="(objectUUID=0123456789abcde2)")
|
||||
self.assertEqual(len(res3), 1)
|
||||
self.assertEqual(str(res3[0].dn), "OU=DUP2,DC=SAMBA,DC=ORG")
|
||||
|
||||
try:
|
||||
self.l.rename("OU=DUP,DC=SAMBA,DC=ORG",
|
||||
"OU=DUP2,DC=SAMBA,DC=ORG")
|
||||
|
Loading…
Reference in New Issue
Block a user