Rev 4: Update the test suite to work with dirstate trees. in http://bzr.arbash-meinel.com/plugins/merge_into

John Arbash Meinel john at arbash-meinel.com
Wed Mar 21 21:16:27 GMT 2007


At http://bzr.arbash-meinel.com/plugins/merge_into

------------------------------------------------------------
revno: 4
revision-id: john at arbash-meinel.com-20070321211626-9s6vnmddbwfoth96
parent: john at arbash-meinel.com-20070201232050-v1z4iq6f6zk6p5yp
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: merge_into
timestamp: Wed 2007-03-21 16:16:26 -0500
message:
  Update the test suite to work with dirstate trees.
modified:
  test_bb_merge_into.py          test_bb_merge_into.p-20070131214328-dide73mgytkt6kk2-2
-------------- next part --------------
=== modified file 'test_bb_merge_into.py'
--- a/test_bb_merge_into.py	2007-02-01 23:20:50 +0000
+++ b/test_bb_merge_into.py	2007-03-21 21:16:26 +0000
@@ -35,15 +35,17 @@
         project_wt = self.make_branch_and_tree('project')
         self.build_tree(['project/README', 'project/dir/',
                          'project/dir/file.c'])
-        project_wt.add(['', 'README', 'dir', 'dir/file.c'],
-                       [proj_root, 'readme-id', 'dir-id', 'file.c-id'])
+        project_wt.set_root_id(proj_root)
+        project_wt.add(['README', 'dir', 'dir/file.c'],
+                       ['readme-id', 'dir-id', 'file.c-id'])
         project_wt.commit('Initial project', rev_id='project-1')
 
         lib_wt = self.make_branch_and_tree('lib1')
         self.build_tree(['lib1/README', 'lib1/Makefile',
                          'lib1/foo.c'])
-        lib_wt.add(['', 'README', 'Makefile', 'foo.c'],
-                   [lib_root, 'readme-lib-id', 'makefile-lib-id',
+        lib_wt.set_root_id(lib_root)
+        lib_wt.add(['README', 'Makefile', 'foo.c'],
+                   ['readme-lib-id', 'makefile-lib-id',
                     'foo.c-lib-id'])
         lib_wt.commit('Initial lib project', rev_id='lib-1')
 
@@ -57,9 +59,9 @@
 
         # This shouldn't be necessary, but it seems required to get the
         # inventory reloaded
-        project_wt.read_working_inventory()
         project_wt.lock_read()
         try:
+            project_wt.read_working_inventory()
             # The lib-1 revision should be merged into this one
             self.assertEqual(['project-1', 'lib-1'],
                              project_wt.get_parent_ids())
@@ -87,9 +89,9 @@
 
         # This shouldn't be necessary, but it seems required to get the
         # inventory reloaded
-        project_wt.read_working_inventory()
         project_wt.lock_read()
         try:
+            project_wt.read_working_inventory()
             # The lib-1 revision should be merged into this one
             self.assertEqual(['project-1', 'lib-1'],
                              project_wt.get_parent_ids())
@@ -117,9 +119,9 @@
 
         # This shouldn't be necessary, but it seems required to get the
         # inventory reloaded
-        project_wt.read_working_inventory()
         project_wt.lock_read()
         try:
+            project_wt.read_working_inventory()
             # The lib-1 revision should be merged into this one
             self.assertEqual(['project-1', 'lib-1'],
                              project_wt.get_parent_ids())
@@ -148,9 +150,9 @@
 
         # This shouldn't be necessary, but it seems required to get the
         # inventory reloaded
-        project_wt.read_working_inventory()
         project_wt.lock_read()
         try:
+            project_wt.read_working_inventory()
             # The lib-1 revision should be merged into this one
             self.assertEqual(['project-1', 'lib-1'],
                              project_wt.get_parent_ids())



More information about the bazaar-commits mailing list