code coverage tool

Jeremy Hylton jeremy at zope.com
Thu Feb 27 09:20:34 EST 2003


> On Thu, 20 Feb 2003 07:35:06 -0500, Peter Hansen
> <peter at engcorp.com> wrote:
> >phil hunt wrote:
> >>
> >> Is there an open-source code coverage tool for Python? I have a
> >> program for which I have written several unit tests, and I want to
> >> see if any of the lines in my program aren't being exercised by the
> >> tests.
> >
> >Google is your friend.  Try "python coverage" or sprinkle lightly
> >with "test" or "code" or such...
>
> I tried Google; I didn't come up with anything useful.

Look at the trace.py script in Tools/scripts.  It will be in the standard
library in Python 2.3.  This isn't necessarily the best solution, but it the
best we have at the moment.

Jeremy






More information about the Python-list mailing list