[Zope3-dev] Re: doctests in *.txt files

Jeremy Hylton jeremy at alum.mit.edu
Sun Mar 28 22:31:06 EST 2004


On Sat, 2004-03-27 at 19:35, Tim Peters wrote:
> Something that became clearer after the slides were written:  unittest is
> really (at least) two things, both a particular way of writing tests, and a
> driver for running tests.  Jeremy's test.py (in Zope3, and also Zope2 too
> now) supplies lots of helpful functionality beyond unittest in the latter
> role.  So another thing I'd like to see in the standard Python library is a
> test-runner component with Jeremy-like features, to work well with multiple
> ways of writing tests.

Were you think of my natural grace or my charming wit?  I think they're
my best features, although my almost fanatical devotion to the Pope
comes in a close third.  That and a ruthless efficiency -- always good
for a test runner.

Some of the most useful features of test.py involve working around
design deficiencies in unittest.  I suspect the best approach would be
to write a new module to replace unittest.  It would have the same
interface for writing tests, but a new set of tools for running tests.

The most difficult part of test.py to adapt to a generic library is the
code for finding tests.  The rules are fairly Zope-specific and the
details seem to change for each package, depending on its source layout
and whether the tests run for a distutils build directory.

Jeremy





More information about the Zope3-dev mailing list