[TIP] Test discovery for unittest

Olemis Lang olemis at gmail.com
Tue Apr 7 07:03:29 PDT 2009


On Tue, Apr 7, 2009 at 8:58 AM, Marius Gedminas <marius at gedmin.as> wrote:
> On Tue, Apr 07, 2009 at 03:57:59AM +0100, Michael Foord wrote:
>> Douglas Philips wrote:
>> > On or about 2009 Apr 6, at 6:26 PM, John Arbash Meinel indited:
>> >
>> >
>> > I want the regression run to stop if there are any errors.
>
>> I agree.
>
> I disagree.  An import failure should not be silently ignored (or
> reported as a warning), it should be reported at the same level of
> seriousness as a test failure, but it should not preclude other tests
> from being run.
>
> My rationale:
[...]

+1

>> > One could argue that missing tests due to import errors are just
>> > missing tests
>
> And one would be mistaken.
>
> If you want to skip some tests (because of missing dependencies or
> whatnot), do that explicitly, not by letting the import error propagate.
> I believe unittest recently gained support for skipping tests.
>

+1

-- 
Regards,

Olemis.

Blog ES: http://simelo-es.blogspot.com/
Blog EN: http://simelo-en.blogspot.com/

Featured article:
Se retira el BDFL ... ¿El fin de Python 3k?



More information about the testing-in-python mailing list