Re: [Checkins] SVN: zope.app.testing/trunk/ Switch doctests to use the stdlib ``doctest`` module.
Adam GROSZER <[email protected]>
| Newsgroups | gmane.comp.web.zope.devel |
|---|---|
| Message-ID | <[email protected]> |
Hello Tres, Thursday, June 3, 2010, 5:29:41 PM, you wrote: TS> -----BEGIN PGP SIGNED MESSAGE----- TS> Hash: SHA1 TS> Adam GROSZER wrote: >>> Log message for revision 110723: >>> Switch doctests to use the stdlib ``doctest`` module. >>> >>> o Disuse than the deprecated ``zope.testing.doctest`` variant. >>> >>> Remove a duplicated import. >>> >>> >>> Changed: >>> U zope.app.testing/trunk/CHANGES.txt >>> U zope.app.testing/trunk/src/zope/app/testing/functional.py >>> U zope.app.testing/trunk/src/zope/app/testing/tests.py >> >> The problem with this is that it just breaks tests that have accented >> unicode characters. >> >> zope.app.testing.functional.FunctionalDocFileSuite breaks, while >> zope.testing.doctest.DocFileSuite works. >> I don't remember what was the final decision on deprecating >> zope.testing.doctest, but this definitely s*cks. >> >> Thoughts? TS> What tests are breaking? Our apps's tests. Excerpt is: # -*- coding: UTF-8 -*- <snip> >>> mail = mailer.prepareEmail(u"Some subject", ... u"Some body éáÉÁ", ... u"[email protected]", ... u"[email protected]") <snip> With the stdlib doctest prepareEmail gets u'Some body \xc3\xa9\xc3\xa1\xc3\x89\xc3\x81' Note, it's unicode() and utf-8 encoded at the same time. I guess stdlib doctest does not care about # -*- coding: UTF-8 -*- -- Best regards, Adam GROSZER mailto:[email protected] -- Quote of the day: A physicist is an atom's way of knowing about atoms. -- George Wald _______________________________________________ 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 )