From b3314d6ad8de732f563f095ea538c7b95c667d73 Mon Sep 17 00:00:00 2001
From: Kirill Smelkov <kirr@landau.phys.spbu.ru>
Date: Sun, 19 Sep 2010 13:53:32 +0400
Subject: pytdb: Add support for tdb_transaction_prepare_commit()

Cc: 597386@bugs.debian.org
Signed-off-by: Kirill Smelkov <kirr@landau.phys.spbu.ru>
Signed-off-by: Jelmer Vernooij <jelmer@samba.org>
---
 lib/tdb/python/tests/simple.py | 8 ++++++++
 1 file changed, 8 insertions(+)

(limited to 'lib/tdb/python/tests')

diff --git a/lib/tdb/python/tests/simple.py b/lib/tdb/python/tests/simple.py
index abc888c4ed..9ef6d2927b 100644
--- a/lib/tdb/python/tests/simple.py
+++ b/lib/tdb/python/tests/simple.py
@@ -116,6 +116,14 @@ class SimpleTdbTests(TestCase):
         self.tdb.transaction_commit()
         self.assertEquals("1", self.tdb["bloe"])
 
+    def test_transaction_prepare_commit(self):
+        self.tdb["bloe"] = "2"
+        self.tdb.transaction_start()
+        self.tdb["bloe"] = "1"
+        self.tdb.transaction_prepare_commit()
+        self.tdb.transaction_commit()
+        self.assertEquals("1", self.tdb["bloe"])
+
     def test_iterator(self):
         self.tdb["bloe"] = "2"
         self.tdb["bla"] = "hoi"
-- 
cgit