[TIP] How to get coverage.py and unittest2 working together?

Michael Foord fuzzyman at voidspace.org.uk
Thu Jul 22 15:24:00 PDT 2010

On 22/07/2010 21:02, Tim Hatch wrote:
>> In theory something like
>> coverage run unit2 discover
>> should work but it doesn't as coverage expects a .py file to execute.
> I haven't tried, but on *nix maybe this works (but will report on lots
> of unittest2 modules most likely):
> coverage run `which unit2` discover

For what it's worth I'm now prototyping the extension mechanism for 
unittest/unittest2. Anyone who wants to follow along can look at the 
"plugins" branch of the repository at http://hg.python.org/unittest2

It is still early days - only 3 extension points and 4 example plugins. 
coverage is one of the example plugins I will be looking at implementing 
in order to ensure that the plugin mechanism is adequate. Not done yet 

Michael Foord

> Tim
> _______________________________________________
> testing-in-python mailing list
> testing-in-python at lists.idyll.org
> http://lists.idyll.org/listinfo/testing-in-python


More information about the testing-in-python mailing list