diff options
-rw-r--r-- | ChangeLog | 15 | ||||
-rw-r--r-- | testlib.py | 9 |
2 files changed, 22 insertions, 2 deletions
@@ -1,10 +1,23 @@ ChangeLog for logilab.common ============================ - -- +2012-03-22 -- 0.57.2 * texutils: apply_units raise ValueError if string isn'nt valid (closes #88808) + + * daemon: don't call putenv directly + * pytest: do not enable extra warning other than DeprecationWarning. + * testlib: DocTestCase fix builtins pollution after doctest execution. + + * testlib: replace sys.exit with raise ImportError (closes: #84159) + + * fix license in README + + * add trove classifiers (tell about python 3 support for pypi) + + + 2011-10-28 -- 0.57.1 * daemon: change $HOME after dropping privileges (closes #81297) @@ -1214,7 +1214,14 @@ class DocTest(TestCase): suite = doctest.DocTestSuite(self.module) except AttributeError: suite = SkippedSuite() - return suite.run(result) + # doctest may gork the builtins dictionnary + # This happen to the "_" entry used by gettext + old_builtins = __builtins__.copy() + try: + return suite.run(result) + finally: + __builtins__.clear() + __builtins__.update(old_builtins) run = __call__ def test(self): |