Rev 3414: Ian's first review comments. in http://bzr.arbash-meinel.com/branches/bzr/1.4-dev/find_unique_ancestors
John Arbash Meinel
john at arbash-meinel.com
Wed Apr 30 23:38:03 BST 2008
At http://bzr.arbash-meinel.com/branches/bzr/1.4-dev/find_unique_ancestors
------------------------------------------------------------
revno: 3414
revision-id: john at arbash-meinel.com-20080430221814-32fn9bgqi2t5psj6
parent: john at arbash-meinel.com-20080427142151-24uxl2vmwbs93qoa
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: find_unique_ancestors
timestamp: Wed 2008-04-30 17:18:14 -0500
message:
Ian's first review comments.
modified:
NEWS NEWS-20050323055033-4e00b5db738777ff
bzrlib/tests/test_graph.py test_graph_walker.py-20070525030405-enq4r60hhi9xrujc-1
bzrlib/tests/test_status.py test_status.py-20060516190614-fbf6432e4a6e8aa5
-------------- next part --------------
=== modified file 'NEWS'
--- a/NEWS 2008-04-21 16:05:33 +0000
+++ b/NEWS 2008-04-30 22:18:14 +0000
@@ -52,6 +52,10 @@
API BREAKS:
+ * ``bzrlib.status.show_pending_merges`` requires the repository to be
+ locked by the caller. Callers should have been doing it anyway, but it
+ will now raise an exception if they do not. (John Arbash Meinel)
+
bzr 1.4rc1 2008-04-11
---------------------
=== modified file 'bzrlib/tests/test_graph.py'
--- a/bzrlib/tests/test_graph.py 2008-04-27 14:21:51 +0000
+++ b/bzrlib/tests/test_graph.py 2008-04-30 22:18:14 +0000
@@ -164,7 +164,7 @@
# Complex shortcut
# This has a failure mode in that a shortcut will find some nodes in common,
-# but the common searcher won't have time to find that one branche is actually
+# but the common searcher won't have time to find that one branch is actually
# in common. The extra nodes at the beginning are because we want to avoid
# walking off the graph. Specifically, node G should be considered common, but
# is likely to be seen by M long before the common searcher finds it.
@@ -602,9 +602,6 @@
def test_graph_difference_extended_history(self):
graph = self.make_graph(extended_history_shortcut)
- # self.expectFailure('find_difference cannot handle shortcuts',
- # self.assertEqual, (set(['e']), set(['f'])),
- # graph.find_difference('e', 'f'))
self.assertEqual((set(['e']), set(['f'])),
graph.find_difference('e', 'f'))
self.assertEqual((set(['f']), set(['e'])),
@@ -617,9 +614,6 @@
def test_graph_difference_complex_shortcut(self):
graph = self.make_graph(complex_shortcut)
- # self.expectFailure('find_difference cannot handle shortcuts',
- # self.assertEqual, (set(['m']), set(['h', 'n'])),
- # graph.find_difference('m', 'n'))
self.assertEqual((set(['m', 'i', 'e']), set(['n', 'h'])),
graph.find_difference('m', 'n'))
@@ -630,9 +624,6 @@
def test_graph_difference_shortcut_extra_root(self):
graph = self.make_graph(shortcut_extra_root)
- # self.expectFailure('find_difference cannot handle shortcuts',
- # self.assertEqual, (set(['e']), set(['f', 'g'])),
- # graph.find_difference('e', 'f'))
self.assertEqual((set(['e']), set(['f', 'g'])),
graph.find_difference('e', 'f'))
@@ -821,13 +812,6 @@
self.fail('key deeper was accessed')
result[key] = graph_dict[key]
return result
- def get_parent_map(keys):
- result = {}
- for key in keys:
- if key == 'deeper':
- self.fail('key deeper was accessed')
- result[key] = graph_dict[key]
- return result
an_obj = stub()
an_obj.get_parent_map = get_parent_map
graph = _mod_graph.Graph(an_obj)
=== modified file 'bzrlib/tests/test_status.py'
--- a/bzrlib/tests/test_status.py 2008-04-22 20:04:49 +0000
+++ b/bzrlib/tests/test_status.py 2008-04-30 22:18:14 +0000
@@ -49,7 +49,7 @@
tree2 = tree.bzrdir.clone('b').open_workingtree()
tree.commit('commit 2', timestamp=1196796819, timezone=0)
tree2.commit('commit 2b', timestamp=1196796819, timezone=0)
- tree3 = tree.bzrdir.clone('c').open_workingtree()
+ tree3 = tree2.bzrdir.clone('c').open_workingtree()
tree2.commit('commit 3b', timestamp=1196796819, timezone=0)
tree3.commit('commit 3c', timestamp=1196796819, timezone=0)
tree.merge_from_branch(tree2.branch)
@@ -60,8 +60,8 @@
show_pending_merges(tree, output)
finally:
tree.unlock()
- # Even though 2b is merged by 3c also, it should only be displayed
- # the first time it shows u.
+ # Even though 2b is in the ancestry of 3c, it should only be displayed
+ # under the first merge parent.
self.assertEqual('pending merges:\n'
' Joe Foo 2007-12-04 commit 3b\n'
' Joe Foo 2007-12-04 commit 2b\n'
More information about the bazaar-commits
mailing list