summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_int.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_int.py')
-rw-r--r--Lib/test/test_int.py13
1 files changed, 7 insertions, 6 deletions
diff --git a/Lib/test/test_int.py b/Lib/test/test_int.py
index ab463a0..0ea5772 100644
--- a/Lib/test/test_int.py
+++ b/Lib/test/test_int.py
@@ -53,15 +53,15 @@ class IntTestCases(unittest.TestCase):
s = repr(-1-sys.maxsize)
x = int(s)
self.assertEqual(x+1, -sys.maxsize)
- self.assertTrue(isinstance(x, int))
- # should return long
+ self.assertIsInstance(x, int)
+ # should return int
self.assertEqual(int(s[1:]), sys.maxsize+1)
- # should return long
+ # should return int
x = int(1e100)
- self.assertTrue(isinstance(x, int))
+ self.assertIsInstance(x, int)
x = int(-1e100)
- self.assertTrue(isinstance(x, int))
+ self.assertIsInstance(x, int)
# SF bug 434186: 0x80000000/2 != 0x80000000>>1.
@@ -79,7 +79,8 @@ class IntTestCases(unittest.TestCase):
self.assertRaises(ValueError, int, '123\x00 245', 20)
x = int('1' * 600)
- self.assertTrue(isinstance(x, int))
+ self.assertIsInstance(x, int)
+
self.assertRaises(TypeError, int, 1, 12)