diff options
author | Georg Brandl <georg@python.org> | 2010-02-07 12:01:19 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2010-02-07 12:01:19 (GMT) |
commit | 708c487abe105843a77b556dc3ddcb7a00cfd7cc (patch) | |
tree | 8a29df776607589821275fb964e1062a6c3db73a /Lib/test/test_long.py | |
parent | 9d2fde7235f54d0feed91c451dadef118c982eff (diff) | |
download | cpython-708c487abe105843a77b556dc3ddcb7a00cfd7cc.zip cpython-708c487abe105843a77b556dc3ddcb7a00cfd7cc.tar.gz cpython-708c487abe105843a77b556dc3ddcb7a00cfd7cc.tar.bz2 |
Merged revisions 78035,78040,78043,78049-78050,78052-78054 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r78035 | georg.brandl | 2010-02-06 23:44:17 +0100 (Sa, 06 Feb 2010) | 1 line
Fix duplicate import.
........
r78040 | georg.brandl | 2010-02-07 00:08:00 +0100 (So, 07 Feb 2010) | 1 line
Fix a few UnboundLocalErrors in test_long.
........
r78043 | georg.brandl | 2010-02-07 00:12:19 +0100 (So, 07 Feb 2010) | 1 line
Remove duplicate test method.
........
r78049 | georg.brandl | 2010-02-07 00:33:33 +0100 (So, 07 Feb 2010) | 1 line
Fix import/access for some identifiers. _TestSharedCTypes does not seem to be executed?
........
r78050 | georg.brandl | 2010-02-07 00:34:10 +0100 (So, 07 Feb 2010) | 1 line
Fix more unbound locals in code paths that do not seem to be used.
........
r78052 | georg.brandl | 2010-02-07 00:54:04 +0100 (So, 07 Feb 2010) | 1 line
Add missing import when running these tests standalone.
........
r78053 | georg.brandl | 2010-02-07 00:54:43 +0100 (So, 07 Feb 2010) | 1 line
Fix some name errors in Mac modules.
........
r78054 | georg.brandl | 2010-02-07 00:58:25 +0100 (So, 07 Feb 2010) | 1 line
Add missing import.
........
Diffstat (limited to 'Lib/test/test_long.py')
-rw-r--r-- | Lib/test/test_long.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/Lib/test/test_long.py b/Lib/test/test_long.py index 5addd2e..a91b644 100644 --- a/Lib/test/test_long.py +++ b/Lib/test/test_long.py @@ -506,7 +506,7 @@ class LongTest(unittest.TestCase): except OverflowError: self.fail("int(long(sys.maxint)) overflowed!") if not isinstance(x, int): - raise TestFailed("int(long(sys.maxint)) should have returned int") + self.fail("int(long(sys.maxint)) should have returned int") x = int(hugeneg_aslong) try: self.assertEqual(x, hugeneg, @@ -514,8 +514,7 @@ class LongTest(unittest.TestCase): except OverflowError: self.fail("int(long(-sys.maxint-1)) overflowed!") if not isinstance(x, int): - raise TestFailed("int(long(-sys.maxint-1)) should have " - "returned int") + self.fail("int(long(-sys.maxint-1)) should have returned int") # but long -> int should overflow for hugepos+1 and hugeneg-1 x = hugepos_aslong + 1 try: @@ -714,7 +713,7 @@ class LongTest(unittest.TestCase): self.d = d assert float(n) / float(d) == value else: - raise TypeError("can't deal with %r" % val) + raise TypeError("can't deal with %r" % value) def __cmp__(self, other): if not isinstance(other, Rat): |