Questions after testtools merge

John Arbash Meinel john at arbash-meinel.com
Wed Dec 30 22:14:28 GMT 2009


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Martin (gzlist) wrote:
> On 30/12/2009, Martin (gzlist) <gzlist at googlemail.com> wrote:
>> Haven't dug into this further yet, but I suspect that bazaar is
>> corrupting the environment block when doing the codepage-switching
>> attempts. Why testtools does this when the previous testing code
>> didn't I have no idea.
> 
> Okay, so, the behaviour change seems to be that testtools doesn't call
> tearDown if TestSkipped is raised. I don't know if it's a deliberate
> difference, but that's what caused the regression. Well,
> bb.test_non_ascii is dodgy anyway, but if tearDown is not called then
> osutils._cached_user_encoding is left as some bogus value that then
> gets used to trample over various things later on. Setting
> os.environ['BZR_EMAIL'] prior to the skip check is a worry as well
> though.
> 
> Martin
> 
> 

So I'm pretty sure that always calling tearDown *was* something that we
had to explicitly put into our .run() method. And it certainly could
have been lost in the transition.

That said, we've moved to the 'addCleanup()' style of teardown, so we
could just switch those failing tests over to the new way of doing things.

John
=:->

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAks70MQACgkQJdeBCYSNAAP9SgCfUlas7I6oJ5tsk6UGhid04AlP
nCIAnA4eVKJwXK+OhGuN7IDJ5W8DyqeI
=HBS5
-----END PGP SIGNATURE-----



More information about the bazaar mailing list