Question

I have already visited Preferred Python unit-testing framework. I am not just looking at Python Unit Testing Framework, but also code coverage with respect to unit tests. So far I have only come across coverage.py. Is there any better option?

An interesting option for me is to integrate cpython, unit testing of Python code and code coverage of Python code with Visual Studio 2008 through plugins (something similar to IronPython Studio). What can be done to achieve this? I look forward to suggestions.

Was it helpful?

Solution

PyDev seems to allow code coverage from within Eclipse.

I've yet to find how to integrate that with my own (rather complex) build process, so I use Ned Batchelder's coverage.py at the command line.

OTHER TIPS

We use this Django coverage integration, but instead of using the default coverage.py reporting, we generate some simple HTML: Colorize Python source using the built-in tokenizer.

There is also figleaf which I think is based on Ned Batchelder's coverage.py. We use nose as the driver for the testing. It all works pretty well. We write our unit tests using the built-in unittest and doctest modules.

NetBeans' new Python support has tightly integrated code coverage support - more info here.

If you want interactive code coverage, where you can see your coverage stats change in real time, take a look at Python Coverage Validator.

Testoob has a neat "--coverage" command-line option to generate a coverage report.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top