diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2016-05-28 14:48:19 +0300 |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2016-05-28 14:48:19 +0300 |
commit | f5a86603829104d675112c1aa35f4a7bdd32110e (patch) | |
tree | f3427e72d0382510cc719e3817782ae290ab91ad /Lib/test/test_fractions.py | |
parent | 95de54494fb75a30f417c5bba1d0db4d54f57d29 (diff) | |
parent | c7aaeb9022c01fbc190a6c6eb9df9cf7b0c14347 (diff) | |
download | cpython-f5a86603829104d675112c1aa35f4a7bdd32110e.tar.gz |
Issue #27138: Regenerate Python/importlib_external.h.
Diffstat (limited to 'Lib/test/test_fractions.py')
-rw-r--r-- | Lib/test/test_fractions.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/Lib/test/test_fractions.py b/Lib/test/test_fractions.py index 1699852216..73d2dd3031 100644 --- a/Lib/test/test_fractions.py +++ b/Lib/test/test_fractions.py @@ -263,13 +263,13 @@ class FractionTest(unittest.TestCase): nan = inf - inf # bug 16469: error types should be consistent with float -> int self.assertRaisesMessage( - OverflowError, "Cannot convert inf to Fraction.", + OverflowError, "cannot convert Infinity to integer ratio", F.from_float, inf) self.assertRaisesMessage( - OverflowError, "Cannot convert -inf to Fraction.", + OverflowError, "cannot convert Infinity to integer ratio", F.from_float, -inf) self.assertRaisesMessage( - ValueError, "Cannot convert nan to Fraction.", + ValueError, "cannot convert NaN to integer ratio", F.from_float, nan) def testFromDecimal(self): @@ -284,16 +284,16 @@ class FractionTest(unittest.TestCase): # bug 16469: error types should be consistent with decimal -> int self.assertRaisesMessage( - OverflowError, "Cannot convert Infinity to Fraction.", + OverflowError, "cannot convert Infinity to integer ratio", F.from_decimal, Decimal("inf")) self.assertRaisesMessage( - OverflowError, "Cannot convert -Infinity to Fraction.", + OverflowError, "cannot convert Infinity to integer ratio", F.from_decimal, Decimal("-inf")) self.assertRaisesMessage( - ValueError, "Cannot convert NaN to Fraction.", + ValueError, "cannot convert NaN to integer ratio", F.from_decimal, Decimal("nan")) self.assertRaisesMessage( - ValueError, "Cannot convert sNaN to Fraction.", + ValueError, "cannot convert NaN to integer ratio", F.from_decimal, Decimal("snan")) def testLimitDenominator(self): |