diff options
author | Guido van Rossum <guido@python.org> | 1997-05-14 21:37:23 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 1997-05-14 21:37:23 (GMT) |
commit | c1c96d1b5c5b94edc84c057278a29f4aa7a32453 (patch) | |
tree | 176bd2d8be70a5b77604231455200e12e354b6cf /Lib/test/test_b1.py | |
parent | 8cd70c3555f1f7905604de3dbf624a719327b76c (diff) | |
download | cpython-c1c96d1b5c5b94edc84c057278a29f4aa7a32453.zip cpython-c1c96d1b5c5b94edc84c057278a29f4aa7a32453.tar.gz cpython-c1c96d1b5c5b94edc84c057278a29f4aa7a32453.tar.bz2 |
Fix hex tests for 64-bit machines.
Diffstat (limited to 'Lib/test/test_b1.py')
-rw-r--r-- | Lib/test/test_b1.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Lib/test/test_b1.py b/Lib/test/test_b1.py index 3262bad..8d8a725 100644 --- a/Lib/test/test_b1.py +++ b/Lib/test/test_b1.py @@ -208,7 +208,9 @@ def f(): pass print 'hex' if hex(16) != '0x10': raise TestFailed, 'hex(16)' if hex(16L) != '0x10L': raise TestFailed, 'hex(16L)' -if hex(-16) != '0xfffffff0': raise TestFailed, 'hex(-16)' +if len(hex(-1)) != len(hex(sys.maxint)): raise TestFailed, 'len(hex(-1))' +if hex(-16) not in ('0xfffffff0', '0xfffffffffffffff0'): + raise TestFailed, 'hex(-16)' if hex(-16L) != '-0x10L': raise TestFailed, 'hex(-16L)' print 'id' |