<div dir="ltr"><blockquote style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;" class="gmail_quote"> ------------------------------------------------------------------------<br>
* Vincent Ladeuil <<a href="mailto:v.ladeuil%2Blp@free.fr">v.ladeuil+lp@free.fr</a>> * * 16 July 2008 08:13 *<br> <br> Marius> hi<br> Marius> I changed `bzr init` and `bzr init-repo` to print out<br>
Marius> the same as `bzr info` if it completed successfully<br> Marius> (and if we're not in quiet mode)<br> <br> Marius> I managed to get the tests to pass again (modelled after the<br> info and pull<br>
Marius> tests),<br> Marius> but I'm concerned about:<br> Marius> 1) In <bzrlib/tests/commands/test_init.py> and<br> Marius> <bzrlib/tests/commands/test_init.py><br> Marius> I had to do the following:<br>
Marius> - self.assertEquals(1, len(self.connections))<br> Marius> + self.assertEquals(2, len(self.connections))<br> Marius> I'm not sure if this sort of thing is acceptable or how to<br>
properly fix<br> Marius> it,<br> <br> It is not. The purpose of the test is to check that a single<br> connection to the server is used, for performance reasons but<br> also because the user will be prompted for its password again<br>
otherwise.<br></blockquote><br>thanks for the explanation<br><br>...<br><blockquote style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;" class="gmail_quote"> Marius> + <br>
show_bzrdir_info(bzrdir.BzrDir.open_containing(location)[0],<br> Marius> + verbose=0, outfile=self.outf)<br> <br> I think using open_containing_from_transport(to_transport)<br> instead of open_containing(location), will make the test pass<br>
again.<br> <br> Alternatively you can do open_containing(location,<br> possible_transports=[to_transport]).<br> <br> By using 'location' you force bzrdir to create a new transport,<br> breaking the existing relation between location and to_transport,<br>
defeating the connection sharing mechanism.<br></blockquote><br>Thank you so much for the explanation and suggestions, I was really stuck.<br>I opted for your alternate solution, and it worked like a bomb!<br><br>I attached the diff since my previous patch, for your reviewing convenience.<br>
<br>regards<br>Marius<br></div>