From 6d30c3e39110e90d90066208d1f05240d51f91e1 Mon Sep 17 00:00:00 2001 From: Tim Peters Date: Wed, 5 Dec 2001 00:30:09 +0000 Subject: [PATCH] Change new tests to use integer division (// instead of /). --- Lib/test/test_types.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Lib/test/test_types.py b/Lib/test/test_types.py index 3af31132e69..2ea0c6b89be 100644 --- a/Lib/test/test_types.py +++ b/Lib/test/test_types.py @@ -74,7 +74,7 @@ if not (xsize*ysize*zsize == zsize*xsize*ysize == 338912): # And another. m = -sys.maxint - 1 for divisor in 1, 2, 4, 8, 16, 32: - j = m / divisor + j = m // divisor prod = divisor * j if prod != m: raise TestFailed, "%r * %r == %r != %r" % (divisor, j, prod, m) @@ -83,7 +83,7 @@ for divisor in 1, 2, 4, 8, 16, 32: type(prod)) # Check for expected * overflow to long. for divisor in 1, 2, 4, 8, 16, 32: - j = m / divisor - 1 + j = m // divisor - 1 prod = divisor * j if type(prod) is not long: raise TestFailed, ("expected type(%r) to be long, not %r" % @@ -91,7 +91,7 @@ for divisor in 1, 2, 4, 8, 16, 32: # Check for expected * overflow to long. m = sys.maxint for divisor in 1, 2, 4, 8, 16, 32: - j = m / divisor + 1 + j = m // divisor + 1 prod = divisor * j if type(prod) is not long: raise TestFailed, ("expected type(%r) to be long, not %r" %