Rev 5615: (vila) Merge 2.3 into trunk including fix for bug #660935 (Vincent in file:///home/pqm/archives/thelove/bzr/%2Btrunk/

Canonical.com Patch Queue Manager pqm at pqm.ubuntu.com
Sat Jan 15 20:19:47 UTC 2011


At file:///home/pqm/archives/thelove/bzr/%2Btrunk/

------------------------------------------------------------
revno: 5615 [merge]
revision-id: pqm at pqm.ubuntu.com-20110115201943-es5zdz223vtgweyf
parent: pqm at pqm.ubuntu.com-20110115074217-fefylwf2f7wf9vz5
parent: v.ladeuil+lp at free.fr-20110115194323-600qx58shsrp66o0
committer: Canonical.com Patch Queue Manager <pqm at pqm.ubuntu.com>
branch nick: +trunk
timestamp: Sat 2011-01-15 20:19:43 +0000
message:
  (vila) Merge 2.3 into trunk including fix for bug #660935 (Vincent
  	Ladeuil)
modified:
  bzrlib/conflicts.py            conflicts.py-20051001061850-78ef952ba63d2b42
  bzrlib/tests/test_conflicts.py test_conflicts.py-20051006031059-e2dad9bbeaa5891f
  doc/en/release-notes/bzr-2.3.txt NEWS-20050323055033-4e00b5db738777ff
=== modified file 'bzrlib/conflicts.py'
--- a/bzrlib/conflicts.py	2011-01-10 22:20:12 +0000
+++ b/bzrlib/conflicts.py	2011-01-15 17:29:41 +0000
@@ -514,7 +514,7 @@
         # Adjust the path for the retained file id
         tid = tt.trans_id_file_id(file_id)
         parent_tid = tt.get_tree_parent(tid)
-        tt.adjust_path(path, parent_tid, tid)
+        tt.adjust_path(osutils.basename(path), parent_tid, tid)
         tt.apply()
 
     def _revision_tree(self, tree, revid):
@@ -600,7 +600,7 @@
         # 'item.suffix_to_remove' has been deleted, this is a no-op)
         this_tid = tt.trans_id_file_id(self.file_id)
         parent_tid = tt.get_tree_parent(this_tid)
-        tt.adjust_path(self.path, parent_tid, this_tid)
+        tt.adjust_path(osutils.basename(self.path), parent_tid, this_tid)
         tt.apply()
 
     def action_take_this(self, tree):

=== modified file 'bzrlib/tests/test_conflicts.py'
--- a/bzrlib/tests/test_conflicts.py	2011-01-12 01:01:53 +0000
+++ b/bzrlib/tests/test_conflicts.py	2011-01-15 17:31:18 +0000
@@ -427,6 +427,15 @@
               dict(actions='modify_file', check='file_has_more_content')),
              ('file_deleted',
               dict(actions='delete_file', check='file_doesnt_exist')),),
+            # File modified/deleted in dir
+            (dict(_base_actions='create_file_in_dir',
+                  _path='dir/file', _file_id='file-id'),
+             ('file_modified_in_dir',
+              dict(actions='modify_file_in_dir',
+                   check='file_in_dir_has_more_content')),
+             ('file_deleted_in_dir',
+              dict(actions='delete_file',
+                   check='file_in_dir_doesnt_exist')),),
             ])
 
     def do_create_file(self):
@@ -444,6 +453,19 @@
     def check_file_doesnt_exist(self):
         self.failIfExists('branch/file')
 
+    def do_create_file_in_dir(self):
+        return [('add', ('dir', 'dir-id', 'directory', '')),
+                ('add', ('dir/file', 'file-id', 'file', 'trunk content\n'))]
+
+    def do_modify_file_in_dir(self):
+        return [('modify', ('file-id', 'trunk content\nmore content\n'))]
+
+    def check_file_in_dir_has_more_content(self):
+        self.assertFileEqual('trunk content\nmore content\n', 'branch/dir/file')
+
+    def check_file_in_dir_doesnt_exist(self):
+        self.failIfExists('branch/dir/file')
+
     def _get_resolve_path_arg(self, wt, action):
         return self._path
 
@@ -475,6 +497,16 @@
                    # PathConflicts deletion handling requires a special
                    # hard-coded value
                    path='<deleted>', file_id='file-id')),),
+            # File renamed/deleted in dir
+            (dict(_base_actions='create_file_in_dir'),
+             ('file_renamed_in_dir',
+              dict(actions='rename_file_in_dir', check='file_in_dir_renamed',
+                   path='dir/new-file', file_id='file-id')),
+             ('file_deleted',
+              dict(actions='delete_file', check='file_in_dir_doesnt_exist',
+                   # PathConflicts deletion handling requires a special
+                   # hard-coded value
+                   path='<deleted>', file_id='file-id')),),
             # File renamed/renamed differently
             (dict(_base_actions='create_file'),
              ('file_renamed',
@@ -549,6 +581,20 @@
     def check_dir_doesnt_exist(self):
         self.failIfExists('branch/dir')
 
+    def do_create_file_in_dir(self):
+        return [('add', ('dir', 'dir-id', 'directory', '')),
+                ('add', ('dir/file', 'file-id', 'file', 'trunk content\n'))]
+
+    def do_rename_file_in_dir(self):
+        return [('rename', ('dir/file', 'dir/new-file'))]
+
+    def check_file_in_dir_renamed(self):
+        self.failIfExists('branch/dir/file')
+        self.failUnlessExists('branch/dir/new-file')
+
+    def check_file_in_dir_doesnt_exist(self):
+        self.failIfExists('branch/dir/file')
+
     def _get_resolve_path_arg(self, wt, action):
         tpath = self._this['path']
         opath = self._other['path']

=== modified file 'doc/en/release-notes/bzr-2.3.txt'
--- a/doc/en/release-notes/bzr-2.3.txt	2011-01-14 17:18:23 +0000
+++ b/doc/en/release-notes/bzr-2.3.txt	2011-01-15 19:43:23 +0000
@@ -5,6 +5,58 @@
 .. toctree::
    :maxdepth: 1
 
+bzr 2.3.0
+#########
+
+:2.3.0: NOT RELEASED YET
+
+External Compatibility Breaks
+*****************************
+
+.. These may require users to change the way they use Bazaar.
+
+New Features
+************
+
+.. New commands, options, etc that users may wish to try out.
+
+Improvements
+************
+
+.. Improvements to existing commands, especially improved performance 
+   or memory usage, or better results.
+
+Bug Fixes
+*********
+
+.. Fixes for situations where bzr would previously crash or give incorrect
+   or undesirable results.
+
+Documentation
+*************
+
+.. Improved or updated documentation.
+
+API Changes
+***********
+
+.. Changes that may require updates in plugins or other code that uses
+   bzrlib.
+
+Internals
+*********
+
+.. Major internal changes, unlikely to be visible to users or plugin 
+   developers, but interesting for bzr developers.
+
+Testing
+*******
+
+.. Fixes and changes that are only relevant to bzr's test framework and 
+   suite.  This can include new facilities for writing tests, fixes to 
+   spurious test failures and changes to the way things should be tested.
+
+
 bzr 2.3b5
 #########
 




More information about the bazaar-commits mailing list