This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vstinner
Recipients barry, python-dev, rkuska, serhiy.storchaka, vstinner
Date 2015-09-24.07:57:59
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1443081480.09.0.28802282295.issue22032@psf.upfronthosting.co.za>
In-reply-to
Content
Barry, Robert: I'm sorry that the change broke tests, but tests should not rely on the exact representation. They can test type(obj).__name__ for example.

Barry: "people should be aware that this can break doctests"

Some years ago, I was a big fan of doctest. But with the release of Python 3, I now think that it's a big mess. It's very hard to write reliable doctests. Most doctests rely on the exact representation of objects and subtle details which break on minor Python releases.

IHMO it's better to write classic unittest tests and use functions like assertEqual(). By the way, the unittest made great progress last years, it shows better error message when a test fails.

Maybe we should document better such changes in the https://docs.python.org/dev/whatsnew/3.5.html#porting-to-python-3-5 section ?
History
Date User Action Args
2015-09-24 07:58:00vstinnersetrecipients: + vstinner, barry, python-dev, serhiy.storchaka, rkuska
2015-09-24 07:58:00vstinnersetmessageid: <1443081480.09.0.28802282295.issue22032@psf.upfronthosting.co.za>
2015-09-24 07:58:00vstinnerlinkissue22032 messages
2015-09-24 07:57:59vstinnercreate