Permalink
Browse files

Get first sibling's vclock so it's less confusing.

  • Loading branch information...
1 parent f1abbda commit 79717515b6144caeabb205017724e839c6c85815 @bretthoerner committed Aug 9, 2011
Showing with 16 additions and 3 deletions.
  1. +15 −2 tests/tests.py
  2. +1 −1 timak/timelines.py
View
@@ -1,6 +1,19 @@
import unittest2
+import riak
+from timak.timelines import Timeline
+
class TimakTest(unittest2.TestCase):
- def test_add(self):
- self.assertEqual(1, 1)
+ def setUp(self):
+ self.key = self.bucket = "test-timak"
+ self.c1 = riak.RiakClient()
+ self.c2 = riak.RiakClient()
+
+ self.c1.bucket(self.bucket).set_allow_multiples(True)
+
+ def tearDown(self):
+ riak.RiakClient().bucket(self.bucket).get(self.key).delete()
+
+ def test_add1(self):
+ pass
View
@@ -77,7 +77,7 @@ def _get_obj_and_data(self, key, write_merged=True):
resolved_data = reduce(self._merge_two, data)
# NOTE: is this really the only way to fix a conflict in the
# python riak library?
- obj._vclock = obj.get_sibling(1).vclock()
+ obj._vclock = obj.get_sibling(0).vclock()
if write_merged:
obj.set_data(self._dict_to_list(resolved_data)[:self.max_items])

0 comments on commit 7971751

Please sign in to comment.