Rev 5865: And now we add a bunch more tests, and finally have a failing case. in http://bazaar.launchpad.net/~jameinel/bzr/2.4-set-parent-trees-delta-282941

John Arbash Meinel john at arbash-meinel.com
Thu May 19 09:12:16 UTC 2011


At http://bazaar.launchpad.net/~jameinel/bzr/2.4-set-parent-trees-delta-282941

------------------------------------------------------------
revno: 5865
revision-id: john at arbash-meinel.com-20110519091207-q562yw9n90nnfcdf
parent: john at arbash-meinel.com-20110519090443-lb9tenkbkppzj846
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: 2.4-set-parent-trees-delta-282941
timestamp: Thu 2011-05-19 11:12:07 +0200
message:
  And now we add a bunch more tests, and finally have a failing case.
-------------- next part --------------
=== modified file 'bzrlib/tests/test_dirstate.py'
--- a/bzrlib/tests/test_dirstate.py	2011-05-19 09:04:43 +0000
+++ b/bzrlib/tests/test_dirstate.py	2011-05-19 09:12:07 +0000
@@ -2508,13 +2508,6 @@
         self.assertEqual(state._dirblocks, state2._dirblocks)
         return state
 
-    def test_add_file_matching_active_state(self):
-        state = self.assertUpdate(
-            active=[('file', 'file-id')],
-            basis =[],
-            target=[('file', 'file-id')],
-            )
-
     def test_remove_file_matching_active_state(self):
         state = self.assertUpdate(
             active=[],
@@ -2528,3 +2521,46 @@
             basis =[('file', 'file-id')],
             target=[],
             )
+
+    def test_remove_file_present_elsewhere_in_active_state(self):
+        state = self.assertUpdate(
+            active=[('other-file', 'file-id')],
+            basis =[('file', 'file-id')],
+            target=[],
+            )
+
+    def test_remove_file_active_state_has_diff_file(self):
+        state = self.assertUpdate(
+            active=[('file', 'file-id-2')],
+            basis =[('file', 'file-id')],
+            target=[],
+            )
+
+    def test_remove_file_active_state_has_diff_file_and_file_elsewhere(self):
+        state = self.assertUpdate(
+            active=[('file', 'file-id-2'),
+                    ('other-file', 'file-id')],
+            basis =[('file', 'file-id')],
+            target=[],
+            )
+
+    def test_add_file_matching_active_state(self):
+        state = self.assertUpdate(
+            active=[('file', 'file-id')],
+            basis =[],
+            target=[('file', 'file-id')],
+            )
+
+    def test_add_file_missing_in_active_state(self):
+        state = self.assertUpdate(
+            active=[],
+            basis =[],
+            target=[('file', 'file-id')],
+            )
+
+    def test_add_file_elsewhere_in_active_state(self):
+        state = self.assertUpdate(
+            active=[('other-file', 'file-id')],
+            basis =[],
+            target=[('file', 'file-id')],
+            )



More information about the bazaar-commits mailing list