[MERGE] Convert tests.blackbox.test_[pull|nick] to use internals where appropriate
John Arbash Meinel
john at arbash-meinel.com
Tue Aug 14 17:31:08 BST 2007
John Arbash Meinel has voted tweak.
Status is now: Semi-approved
Comment:
- self.run_bzr('pull -d %s .' % c_url)
+ self.run_bzr('pull -d %s a' % c_url)
^- I think this will fail if the user is in a directory with a space in
the path.
It would be better (IMO) to do:
self.run_bzr(['pull', '-d', c_url, a'])
(This may not be a real problem, since a URL cannot have spaces in it,
they would be encoded to %20. But it just 'feels' better)
self.assertEqual(out, 'No revisions to pull.\n')
+
+
+ def get_rh(self, tree, expected_len):
+ # Make sure we don't have trailing empty revisions
+ rh = tree.branch.revision_history()
+ self.assertEqual(len(rh), expected_len)
+ return rh
^- Only 1 blank line between functions in the same class.
Also, this function seems to be added in a random location (at the
end?).
It would probably be better to ]add it in an alphabetical location.
Though I tend to have "support" functions at the top, and then all
test_* functions coming after them. (alphabetical would still cause
this, in this case)
For details, see:
http://bundlebuggy.aaronbentley.com/request/%3C46B92359.4010707%40warwick.ac.uk%3E
More information about the bazaar
mailing list