[MERGE] fix up test_bench_history
John Arbash Meinel
john at arbash-meinel.com
Tue Aug 22 15:55:19 BST 2006
Aaron Bentley wrote:
> Hi all,
>
> test_bench_history is inappropriately affected by the cwd.
>
> Specifically, it assumes that it is being run from a bzr.dev tree, and
> will fail if 'bzr selftest test_bench_history' is run in a directory
> other than the bzr tree.
>
> This bundle fixes that by opening the tree containing the module under test.
>
> It also nices up the test, changing a convoluted way of getting
> last_revision to the standard way, and using assertEndsWith instead of
> assert_(str.endswith)
>
> And no, there's no pattern that matches revision-ids in general. They
> are free-form*. You could probably write a pattern to match the ones
> generated by bzr, at least right now, but it could go out of date.
>
> Aaron
>
> * technically, revision ids ending in ':' are reserved, and ':' is
> otherwise used to separate namespaces, but these are just conventions.
Looks good to me.
Only problem I see is that it won't work on an installed bzr.
So if we can check for that (say by catching NotBranchError, and just
raising TestSkipped).
+1 either way. And seems trivial enough for 0.10.
John
=:->
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 254 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060822/ba4f86e9/attachment.pgp
More information about the bazaar
mailing list