1
0
mirror of https://github.com/samba-team/samba.git synced 2025-12-06 16:23:49 +03:00

ldb/python: Allow comparing a MessageElement to a list or a singleton.

This commit is contained in:
Jelmer Vernooij
2008-01-11 01:55:56 +01:00
parent a8f90ed34c
commit 1ccbab81d7
3 changed files with 22 additions and 10 deletions

View File

@@ -392,6 +392,12 @@ class MessageElementTests(unittest.TestCase):
x = ldb.MessageElement(["foo", "bar"])
self.assertEquals(2, len(x))
def test_eq(self):
x = ldb.MessageElement(["foo", "bar"])
self.assertEquals(["foo", "bar"], x)
x = ldb.MessageElement(["foo"])
self.assertEquals("foo", x)
class ExampleModule:
name = "example"