Re: zope.testing 3.8.6 emits deprecation warnings from itself?
Marius Gedminas <[email protected]>
| Newsgroups | gmane.comp.web.zope.devel |
|---|---|
| Message-ID | <20091230162946.GB11346@platonas> |
On Wed, Dec 30, 2009 at 03:08:26PM +0100, Lennart Regebro wrote: > On Wed, Dec 30, 2009 at 13:45, Marius Gedminas <[email protected]> wrote: > > I don't remember, exactly, I was just grepping the diffs for > > DocTestFailureException. It's probably the bit that lets bin/test -c > > colorize things like diffs, and tracebacks in doctest failures. > > If that's the case, I'd truly hate to lose this feature, it helps me > > immensely. > > OK, so that colorizing support could probably also be moved into stdlib. > If someone (ie you, you seem to be on top of the problems) get diffs > into the Python tracker then maybe we could get it into Python 2.7 and > 3.2, which would be cool. The only thing needed from doctest.py, AFAIU, is a custom exception class inheriting from AssertionError, so the test runner (which does the colorization) can distinguish doctest errors from regular assertion failures. It should be simple to monkey-patch this too, by setting DocTestCase.failureException, so we can support Python 2.5 through 3.1 > > How mechanical can such a transformation be? Is it sufficient to > > replace > > > > zope.testing.doctest.DocFileSuite('foo.txt', **kw) > > > > with > > > > manuel.testing.TestSuite(manuel.doctest.Manuel(), 'foo.txt', **kw) > > No idea, the Manuel experts need to answer that. :) I was afraid you'd say that... Marius Gedminas -- http://pov.lt/ -- Zope 3 consulting and development _______________________________________________ Zope-Dev maillist - [email protected] https://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - https://mail.zope.org/mailman/listinfo/zope-announce https://mail.zope.org/mailman/listinfo/zope )
signature.asc
(application/pgp-signature, 189 B)
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) iD8DBQFLO3/6kVdEXeem148RAs7qAJ9GiSBc8hfSqeUbrNrrvLDFITFkvQCcCp0r p36Spwslu+auGVPN5ZfZWtI= =UT9V -----END PGP SIGNATURE-----