summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAntoine Pitrou <solipsis@pitrou.net>2013-12-28 15:57:37 (GMT)
committerAntoine Pitrou <solipsis@pitrou.net>2013-12-28 15:57:37 (GMT)
commitc1764dd3506e70d19d1bdda171b7812d416ad92f (patch)
tree9d3a4b5b3a4edb06c22a3774a8c78de5501dd207
parent473f45b4bc7c0c4670ad07f93dbc4a2872c0a6dd (diff)
downloadcpython-c1764dd3506e70d19d1bdda171b7812d416ad92f.zip
cpython-c1764dd3506e70d19d1bdda171b7812d416ad92f.tar.gz
cpython-c1764dd3506e70d19d1bdda171b7812d416ad92f.tar.bz2
Issue #19648: implement empty tests in pickletester. Patch by Gennadiy Zlobin.
-rw-r--r--Lib/test/pickletester.py12
-rw-r--r--Misc/ACKS1
2 files changed, 11 insertions, 2 deletions
diff --git a/Lib/test/pickletester.py b/Lib/test/pickletester.py
index 05befbf..1f59ab2 100644
--- a/Lib/test/pickletester.py
+++ b/Lib/test/pickletester.py
@@ -812,10 +812,18 @@ class AbstractPickleTests(unittest.TestCase):
self.assertEqual(self.dumps(1.2, 0)[0:3], b'F1.')
def test_reduce(self):
- pass
+ for proto in protocols:
+ inst = AAA()
+ dumped = self.dumps(inst, proto)
+ loaded = self.loads(dumped)
+ self.assertEqual(loaded, REDUCE_A)
def test_getinitargs(self):
- pass
+ for proto in protocols:
+ inst = initarg(1, 2)
+ dumped = self.dumps(inst, proto)
+ loaded = self.loads(dumped)
+ self.assert_is_copy(inst, loaded)
def test_pop_empty_stack(self):
# Test issue7455
diff --git a/Misc/ACKS b/Misc/ACKS
index ef6853d..ed5afe7 100644
--- a/Misc/ACKS
+++ b/Misc/ACKS
@@ -1456,4 +1456,5 @@ Uwe Zessin
Cheng Zhang
Kai Zhu
Tarek Ziadé
+Gennadiy Zlobin
Peter Ã…strand