[Python-checkins] r63195 - python/trunk/Lib/test/test_py3kwarn.py

benjamin.peterson python-checkins at python.org
Tue May 13 02:09:46 CEST 2008


Author: benjamin.peterson
Date: Tue May 13 02:09:46 2008
New Revision: 63195

Log:
use .format and fix a bug


Modified:
   python/trunk/Lib/test/test_py3kwarn.py

Modified: python/trunk/Lib/test/test_py3kwarn.py
==============================================================================
--- python/trunk/Lib/test/test_py3kwarn.py	(original)
+++ python/trunk/Lib/test/test_py3kwarn.py	Tue May 13 02:09:46 2008
@@ -133,7 +133,7 @@
                         'ihooks', 'mhlib')
     inclusive_platforms = {'irix' : ('pure',),
                           'darwin' : ('autoGIL', 'Carbon', 'OSATerminology',
-                                      'icglue', 'Nav', 'MacOS', 'aepack', 'aetools'
+                                      'icglue', 'Nav', 'MacOS', 'aepack', 'aetools',
                                       'aetypes', 'applesingle', 'appletrawmain',
                                       'appletrunner', 'argvemulator', 'bgenlocations',
                                       'EasyDialogs', 'macerrors', 'macostools',
@@ -162,11 +162,11 @@
                                  % module_name)
                 except ImportError:
                     if not optional:
-                        self.fail("Non-optional module %s raised an "
-                                  "ImportError." % module_name)
+                        self.fail("Non-optional module {0} raised an "
+                                  "ImportError.".format(module_name))
                 else:
-                    self.fail("DeprecationWarning not raised for %s" %
-                                module_name)
+                    self.fail("DeprecationWarning not raised for {0}"
+                                .format(module_name))
 
     def test_platform_independent_removals(self):
         # Make sure that the modules that are available on all platforms raise


More information about the Python-checkins mailing list