← Back to team overview

launchpad-dev team mailing list archive

Re: New feature in Launchpad TestCase base class

 

On Tue, May 4, 2010 at 2:47 AM, Tim Penhey <tim.penhey@xxxxxxxxxxxxx> wrote:
> Hi All,
>
> In my continued mission to make things easier to test, I've added a new
> feature to the base TestCase class in lp.testing (this makes it in
> TestCaseWithFactory too).
>
> r9327 of db-devel (will be rolled out tonight) contains this change.
>
> The test case class now has an "oopses" attribute.  This is a list that gets
> any oops generated as part of the test appended as it is generated.
>
> This gives any test a deterministic way to determine if any oopses were
> generated.
>

Very cool. Thanks for doing this Tim.

Perhaps we should go a step further and fail tests if they generate
any oopses? It would be easy enough to provide a method that flushes
out the stored oopses list.

jml



Follow ups

References