[Python-checkins] r75995 - python/trunk/Lib/test/test_ascii_formatd.py

eric.smith python-checkins at python.org
Sat Oct 31 18:07:18 CET 2009


Author: eric.smith
Date: Sat Oct 31 18:07:17 2009
New Revision: 75995

Log:
Improved test for a deprecation warning.

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

Modified: python/trunk/Lib/test/test_ascii_formatd.py
==============================================================================
--- python/trunk/Lib/test/test_ascii_formatd.py	(original)
+++ python/trunk/Lib/test/test_ascii_formatd.py	Sat Oct 31 18:07:17 2009
@@ -21,8 +21,7 @@
                                c_double(10.0))
             self.assertEqual(buf.value, '+10.0000000000')
 
-        self.assertEqual(str(w.message), 'PyOS_ascii_formatd is deprecated, '
-                         'use PyOS_double_to_string instead')
+        self.assertEqual(w.category, DeprecationWarning)
 
 class FormatTests(unittest.TestCase):
     # ensure that, for the restricted set of format codes,


More information about the Python-checkins mailing list