[MERGE, 165306] Use the per-file graph during commits of pack's
Robert Collins
robertc at robertcollins.net
Tue Nov 27 22:49:28 GMT 2007
On Tue, 2007-11-27 at 16:40 -0600, John Arbash Meinel wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Robert Collins wrote:
> > On Tue, 2007-11-27 at 17:15 -0500, John Arbash Meinel wrote:
>
> ...
>
> >> I don't see any direct tests for CommitBuilder.heads(). Which seems like
> >> they should be in
> >> bzrlib/tests/repository_implementations/test_commit_builder.py
> >> I only see heads tests for test_graph.py and test_inv.py
> >
> > So, heads() is very heavily, indirectly, tested by the tests for
> > last-modified generation. I'm in two minds here about what to do.
> >
>
> Are we really testing that the file_id graph is correct? It would seem like if
> we were we wouldn't have had the problem of the parents changing because of
> going through a set(). Since that has been cleaned up, the tests may exist now.
Yes, introduced in 0.92 by yours truely.
> > One way would be to migrate those tests to tests for heads(), and a test
> > that heads() is called and used correctly. Another is to consider
> > heads() an implementation internal of the builder (and perhaps make it
> > _heads, though as subclasses need to implement it thats in our grey area
> > for how things are defined as public/private).
> >
> > -Rob
>
> Well, as it is only used by record_entry_contents(), it seems like you could
> simply make it private behind that. And I think most foreign implementations
> would change record_entry_contents (I know SVNCommitBuilder does).
>
> So I'm fine making it more private, and not testing it as much. Though I also
> believe it isn't as tested as you think it is.
I'll give it a _ then.
-Rob
--
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20071128/8e8da707/attachment.pgp
More information about the bazaar
mailing list