[Python-checkins] r64945 - python/trunk/Lib/test/test_sys.py
robert.schuppenies
python-checkins at python.org
Mon Jul 14 10:42:19 CEST 2008
Author: robert.schuppenies
Date: Mon Jul 14 10:42:18 2008
New Revision: 64945
Log:
Fixed test failure on Win64 machines.
Modified:
python/trunk/Lib/test/test_sys.py
Modified: python/trunk/Lib/test/test_sys.py
==============================================================================
--- python/trunk/Lib/test/test_sys.py (original)
+++ python/trunk/Lib/test/test_sys.py Mon Jul 14 10:42:18 2008
@@ -511,9 +511,9 @@
# method-wrapper (descriptor object)
check({}.__iter__, size(h + '2P'))
# dict
- check({}, size(h + '3P2P') + 8*size('P2P'))
+ check({}, size(h + '3P2P' + 8*'P2P'))
x = {1:1, 2:2, 3:3, 4:4, 5:5, 6:6, 7:7, 8:8}
- check(x, size(h + '3P2P') + (8+16)*size('P2P'))
+ check(x, size(h + '3P2P' + 8*'P2P') + 16*size('P2P'))
# dictionary-keyiterator
check({}.iterkeys(), size(h + 'P2PPP'))
# dictionary-valueiterator
@@ -542,9 +542,7 @@
nfrees = len(x.f_code.co_freevars)
extras = x.f_code.co_stacksize + x.f_code.co_nlocals +\
ncells + nfrees - 1
- check(x, size(vh + '12P3i') +\
- CO_MAXBLOCKS*struct.calcsize('3i') +\
- self.P + extras*self.P)
+ check(x, size(vh + '12P3i' + CO_MAXBLOCKS*'3i' + 'P' + extras*'P'))
# function
def func(): pass
check(func, size(h + '9P'))
@@ -612,8 +610,7 @@
# frozenset
PySet_MINSIZE = 8
samples = [[], range(10), range(50)]
- s = size(h + '3P2P') +\
- PySet_MINSIZE*struct.calcsize('lP') + self.l + self.P
+ s = size(h + '3P2P' + PySet_MINSIZE*'lP' + 'lP')
for sample in samples:
minused = len(sample)
if minused == 0: tmp = 1
@@ -646,7 +643,7 @@
# type
# (PyTypeObject + PyNumberMethods + PyMappingMethods +
# PySequenceMethods + PyBufferProcs)
- s = size('P2P15Pl4PP9PP11PI') + size(vh + '41P 10P 3P 6P')
+ s = size(vh + 'P2P15Pl4PP9PP11PI') + size('41P 10P 3P 6P')
class newstyleclass(object):
pass
check(newstyleclass, s)
More information about the Python-checkins
mailing list