[Zope3-checkins] SVN: zope.testing/trunk/ LP: #1055720: Fix failing test on Python 3.3 due to changed exception

Brian Sutherland cvs-admin at zope.org
Fri Sep 28 08:25:30 UTC 2012


Log message for revision 127901:
  LP: #1055720: Fix failing test on Python 3.3 due to changed exception
  messaging.
  

Changed:
  U   zope.testing/trunk/CHANGES.txt
  U   zope.testing/trunk/src/zope/testing/tests.py

-=-
Modified: zope.testing/trunk/CHANGES.txt
===================================================================
--- zope.testing/trunk/CHANGES.txt	2012-09-28 07:54:31 UTC (rev 127900)
+++ zope.testing/trunk/CHANGES.txt	2012-09-28 08:25:27 UTC (rev 127901)
@@ -1,6 +1,12 @@
 zope.testing Changelog
 **********************
 
+4.1.2 (unreleased)
+==================
+
+- LP: #1055720: Fix failing test on Python 3.3 due to changed exception
+  messaging.
+
 4.1.1 (2012-02-01)
 ==================
 

Modified: zope.testing/trunk/src/zope/testing/tests.py
===================================================================
--- zope.testing/trunk/src/zope/testing/tests.py	2012-09-28 07:54:31 UTC (rev 127900)
+++ zope.testing/trunk/src/zope/testing/tests.py	2012-09-28 08:25:27 UTC (rev 127901)
@@ -36,13 +36,13 @@
     suite = unittest.TestSuite((
         doctest.DocFileSuite(
             'module.txt',
-            # when this test is run in isolation, the error message shows the
-            # module name as fully qualified; when it is run as part of the
-            # full test suite, the error message shows the module name as
-            # relative.
+            # Python 3.3 changed exception messaging:
+            #   https://bugs.launchpad.net/zope.testing/+bug/1055720
             checker=renormalizing.RENormalizing([
-                (re.compile('No module named zope.testing.unlikelymodulename'),
-                 'No module named unlikelymodulename')])),
+                (re.compile("No module named '?zope.testing.unlikelymodulename'?"),
+                 'No module named unlikelymodulename'),
+                (re.compile("No module named '?fake'?"),
+                 'No module named fake')])),
         doctest.DocFileSuite('loggingsupport.txt', setUp=setUp),
         doctest.DocFileSuite('renormalizing.txt', setUp=setUp),
         doctest.DocFileSuite('setupstack.txt', setUp=setUp),



More information about the Zope3-Checkins mailing list