diff options
author | Matthias Dieter Wallnöfer <mdw@samba.org> | 2010-06-18 22:17:54 +0200 |
---|---|---|
committer | Matthias Dieter Wallnöfer <mdw@samba.org> | 2010-06-19 17:53:21 +0200 |
commit | c0538a006d5381f3bc17d90f873e791d35bbde17 (patch) | |
tree | cfad3cf58547f9bc17a7445fce1913ee9f30ddc8 | |
parent | ca34ffaaac4cc98dc600cb8b5bc6e8ecf93f7492 (diff) | |
download | samba-c0538a006d5381f3bc17d90f873e791d35bbde17.tar.gz samba-c0538a006d5381f3bc17d90f873e791d35bbde17.tar.bz2 samba-c0538a006d5381f3bc17d90f873e791d35bbde17.zip |
ldb:api.py - add a small test for the enhanced "py_ldb_delete" syntax
-rwxr-xr-x | source4/lib/ldb/tests/python/api.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/source4/lib/ldb/tests/python/api.py b/source4/lib/ldb/tests/python/api.py index 4d9efb4b67..6303f6b6cb 100755 --- a/source4/lib/ldb/tests/python/api.py +++ b/source4/lib/ldb/tests/python/api.py @@ -95,6 +95,15 @@ class SimpleLdb(unittest.TestCase): l = ldb.Ldb(filename()) self.assertRaises(ldb.LdbError, lambda: l.delete(ldb.Dn(l, "dc=foo2"))) + def test_delete_w_unhandled_ctrl(self): + l = ldb.Ldb(filename()) + m = ldb.Message() + m.dn = ldb.Dn(l, "dc=foo1") + m["b"] = ["a"] + l.add(m) + self.assertRaises(ldb.LdbError, lambda: l.delete(m.dn, ["search_options:1:2"])) + l.delete(m.dn) + def test_contains(self): l = ldb.Ldb(filename()) self.assertFalse(ldb.Dn(l, "dc=foo3") in l) |