[Zope3-dev] super-mini proposal for doctestunit.py
Jim Fulton
jim at zope.com
Mon May 10 06:04:42 EDT 2004
Garrett Smith wrote:
> We're making extensive use of doctests and have copied and pasted the
> code from zope/testing/doctestunit.py because it's unusable outside its
> package.
> I'd like to make the following change, which opens up the function for
> general use:
>
> 90c90,98
> < def DocFileSuite(*paths):
> ---
> > def DocFileSuite(package, *paths):
> > """Creates a suite of doctest files.
> >
> > package is the source package containing the doctest files.
> >
> > Each subsequent argument is a string specifying the file name of the
> > doctest relative to the package.
> > """
> >
> 99c107
> < dir = os.path.split(__file__)[0]
> ---
> > dir = os.path.split(package.__file__)[0]
>
> This change has no impact on the Zope core, but I wanted to check with
> the list in case it would break anyone's exsiting testing.
Hm. Dang. I guess this wasn't used. :(
I'd prefer to have the package provided as an optional keyword
argument that defaults to the package containing the calling module.
Jim
--
Jim Fulton mailto:jim at zope.com Python Powered!
CTO (540) 361-1714 http://www.python.org
Zope Corporation http://www.zope.com http://www.zope.org
More information about the Zope3-dev
mailing list