[TIP] while on the subject of unittest...

Michael Foord fuzzyman at voidspace.org.uk
Sun Sep 27 12:27:13 PDT 2009

Fernando Perez wrote:
> Hi Michael,
> Thanks!  For some odd reason, this message only showed up on my inbox
> today, though it appears as from '7 days ago'.  Weird...
> On Mon, Sep 21, 2009 at 3:55 AM, Michael Foord
> <fuzzyman at voidspace.org.uk> wrote:
>> That sounds like a reasonable request - although I'm marginally
>> unsympathetic to people who are subclassing TestProgram in the firstplace as
>> it is an abomination that should never have existed. :-)
>> At some point I'd like to deprecate TestProgram altogether and replace it
>> with something less horrible.
>> Anyway: http://bugs.python.org/issue6956
> Thanks a lot!  I tried to file a bug report but the mail forwarding
> through sourceforge was so slow that I only got the password reset
> many days later, and I'd gotten busy with other things.  Much
> appreciated.

Mail forwarding with sourceforge? You're not trying to use the old 
(defunct) sourceforge bug tracker are you?

> I should say that I have no special attachment to TestProgram at all,
> and in fact all I'd like to have is, *in the standard library*
> something to be able to do what I can get with
> - nosetests  foo
> - nosetests --with-doctest foo
> - nosetests --pdb/--pdb-failures foo
> where foo has reasonably flexible semantics to work at the
> package/module/class/function/single-method levels.
> I use nose for that reason, because it lets me work quickly, though
> nose is probably too much magic for the stdlib.  But anything you guys
> are working on that can make this type of (IMHO critically necessary)
> workflow possible within the stdlib, will only get loud cheers from me
> :)
Well, I don't use nose so don't know the specific semantics of those. 
Filing individual feature requests on the Python bug tracker (not on 
sourceforge) will make it more likely:


Note that with Python head the following command line may already do 
what you want:

    python -m unittest foo


> Best regards,
> f


More information about the testing-in-python mailing list