[Zope3-checkins] SVN: Zope3/trunk/src/zope/configuration/tests/test_config.py test_bad_import(): fix for Python 2.4 too.

Tim Peters tim.one at comcast.net
Mon Aug 2 16:29:14 EDT 2004


Log message for revision 26865:
  test_bad_import():  fix for Python 2.4 too.
  
  I see about 6 other test failures under 2.4.
  


Changed:
  U   Zope3/trunk/src/zope/configuration/tests/test_config.py


-=-
Modified: Zope3/trunk/src/zope/configuration/tests/test_config.py
===================================================================
--- Zope3/trunk/src/zope/configuration/tests/test_config.py	2004-08-02 18:12:31 UTC (rev 26864)
+++ Zope3/trunk/src/zope/configuration/tests/test_config.py	2004-08-02 20:29:13 UTC (rev 26865)
@@ -260,13 +260,12 @@
 
     Cleanup:
 
-    >>> del sys.modules['zope.configuration.tests.victim']
-    >>> del sys.modules['zope.configuration.tests.bad']
-
+    >>> for name in ('zope.configuration.tests.victim',
+    ...              'zope.configuration.tests.bad'):
+    ...    if name in sys.modules:
+    ...        del sys.modules[name]
     """
-    
 
-
 def test_suite():
     return unittest.TestSuite((
         DocTestSuite('zope.configuration.fields'),



More information about the Zope3-Checkins mailing list