[Python-checkins] r76486 - in python/branches/release31-maint: Lib/test/test_float.py
mark.dickinson
python-checkins at python.org
Tue Nov 24 12:00:21 CET 2009
Author: mark.dickinson
Date: Tue Nov 24 12:00:21 2009
New Revision: 76486
Log:
Merged revisions 76485 via svnmerge from
svn+ssh://pythondev@www.python.org/python/branches/py3k
................
r76485 | mark.dickinson | 2009年11月24日 10:59:34 +0000 (2009年11月24日) | 9 lines
Merged revisions 76483 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r76483 | mark.dickinson | 2009年11月24日 10:54:58 +0000 (2009年11月24日) | 2 lines
round(0, "ermintrude") succeeded instead of producing a TypeError. Fix this.
........
................
Modified:
python/branches/release31-maint/ (props changed)
python/branches/release31-maint/Lib/test/test_float.py
Modified: python/branches/release31-maint/Lib/test/test_float.py
==============================================================================
--- python/branches/release31-maint/Lib/test/test_float.py (original)
+++ python/branches/release31-maint/Lib/test/test_float.py Tue Nov 24 12:00:21 2009
@@ -417,6 +417,10 @@
self.assertRaises(OverflowError, round, INF)
self.assertRaises(OverflowError, round, -INF)
self.assertRaises(ValueError, round, NAN)
+ self.assertRaises(TypeError, round, INF, 0.0)
+ self.assertRaises(TypeError, round, -INF, 1.0)
+ self.assertRaises(TypeError, round, NAN, "ceci n'est pas un integer")
+ self.assertRaises(TypeError, round, -0.0, 1j)
@unittest.skipUnless(float.__getformat__("double").startswith("IEEE"),
"test requires IEEE 754 doubles")
More information about the Python-checkins
mailing list