mirror of
https://github.com/python/cpython.git
synced 2025-11-02 11:08:57 +00:00
Issue #3700: make test_bigmem py3k-compatible, and add bytes/bytearray tests
(please note: some of the tests /do/ fail when run with a sufficiently large memory parameter (-M), perhaps because of the str/bytes/bytearray overhaul)
This commit is contained in:
parent
d173589c9d
commit
7cdb495e90
2 changed files with 405 additions and 288 deletions
|
|
@ -609,6 +609,10 @@ def bigmemtest(minsize, memuse, overhead=5*_1M):
|
|||
"""
|
||||
def decorator(f):
|
||||
def wrapper(self):
|
||||
# Retrieve values in case someone decided to adjust them
|
||||
minsize = wrapper.minsize
|
||||
memuse = wrapper.memuse
|
||||
overhead = wrapper.overhead
|
||||
if not max_memuse:
|
||||
# If max_memuse is 0 (the default),
|
||||
# we still want to run the tests with size set to a few kb,
|
||||
|
|
@ -636,6 +640,9 @@ def bigmemtest(minsize, memuse, overhead=5*_1M):
|
|||
def precisionbigmemtest(size, memuse, overhead=5*_1M):
|
||||
def decorator(f):
|
||||
def wrapper(self):
|
||||
size = wrapper.size
|
||||
memuse = wrapper.memuse
|
||||
overhead = wrapper.overhead
|
||||
if not real_max_memuse:
|
||||
maxsize = 5147
|
||||
else:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue