summaryrefslogtreecommitdiffstats
path: root/Lib/test/pickletester.py
diff options
context:
space:
mode:
authorAntoine Pitrou <solipsis@pitrou.net>2011-08-30 21:39:59 (GMT)
committerAntoine Pitrou <solipsis@pitrou.net>2011-08-30 21:39:59 (GMT)
commit2d243494c664376f3ea1130ef79c58cf52717de8 (patch)
tree86b4e0b07227e5342724345fd3207c6bd67890b1 /Lib/test/pickletester.py
parentdd2f8b0b776bdc0ad062f183403aa1b5a2629d39 (diff)
parente897e95880fc8688fd65c9a0df2d58a1817947ba (diff)
downloadcpython-2d243494c664376f3ea1130ef79c58cf52717de8.zip
cpython-2d243494c664376f3ea1130ef79c58cf52717de8.tar.gz
cpython-2d243494c664376f3ea1130ef79c58cf52717de8.tar.bz2
Try to fix one of the bigmem tests in test_pickle
Diffstat (limited to 'Lib/test/pickletester.py')
-rw-r--r--Lib/test/pickletester.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/Lib/test/pickletester.py b/Lib/test/pickletester.py
index f4b50aa..d79aab7 100644
--- a/Lib/test/pickletester.py
+++ b/Lib/test/pickletester.py
@@ -1228,11 +1228,16 @@ class BigmemPickleTests(unittest.TestCase):
finally:
data = None
+ # BINUNICODE (protocols 1, 2 and 3) cannot carry more than
+ # 2**32 - 1 bytes of utf-8 encoded unicode.
+
@precisionbigmemtest(size=_4G, memuse=1 + character_size, dry_run=False)
def test_huge_str_64b(self, size):
data = "a" * size
try:
for proto in protocols:
+ if proto == 0:
+ continue
with self.assertRaises((ValueError, OverflowError)):
self.dumps(data, protocol=proto)
finally: