diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2007-12-22 05:03:02 -0600 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2007-12-24 01:51:01 -0600 |
commit | 249cc734cebfef31320ec10b05dbfaaaa39682ca (patch) | |
tree | d9362b9316ea4bcbbaf561d2d062d01fe574a1d7 /source4/lib/registry/tests/bindings.py | |
parent | 09f820f0bd1a9fc7ffd171418ceb0e19df8e2e43 (diff) | |
download | samba-249cc734cebfef31320ec10b05dbfaaaa39682ca.tar.gz samba-249cc734cebfef31320ec10b05dbfaaaa39682ca.tar.bz2 samba-249cc734cebfef31320ec10b05dbfaaaa39682ca.zip |
r26565: Fix python registry bindings. 'PROVISION_PYTHON=yes make test' works now.
(This used to be commit 485d1fa3d17fe6cc7a0ecd80e8bac42d173bbb19)
Diffstat (limited to 'source4/lib/registry/tests/bindings.py')
-rw-r--r-- | source4/lib/registry/tests/bindings.py | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/source4/lib/registry/tests/bindings.py b/source4/lib/registry/tests/bindings.py index be87efe594..9f93ee9382 100644 --- a/source4/lib/registry/tests/bindings.py +++ b/source4/lib/registry/tests/bindings.py @@ -17,8 +17,10 @@ # along with this program. If not, see <http://www.gnu.org/licenses/>. # +import os import unittest import registry +import samba.tests class HelperTests(unittest.TestCase): def test_predef_to_name(self): @@ -29,6 +31,22 @@ class HelperTests(unittest.TestCase): self.assertEquals("REG_DWORD", registry.str_regtype(4)) + +class HiveTests(samba.tests.TestCaseInTempDir): + def setUp(self): + super(HiveTests, self).setUp() + self.hive = registry.open_ldb(os.path.join(self.tempdir, "ldb_new.ldb")) + + def test_ldb_new(self): + self.assertTrue(self.hive is not None) + + def test_flush(self): + self.hive.flush() + + def test_del_value(self): + self.hive.del_value("FOO") + + class RegistryTests(unittest.TestCase): def test_new(self): self.registry = registry.Registry() |