Kaydet (Commit) 35ad641b authored tarafından Tim Peters's avatar Tim Peters

Build pickler_choices list in a lazier way.

üst 6288e230
...@@ -16,22 +16,11 @@ from datetime import tzinfo ...@@ -16,22 +16,11 @@ from datetime import tzinfo
from datetime import time from datetime import time
from datetime import date, datetime from datetime import date, datetime
pickle_choices = [(pickler, unpickler, proto)
pickle_choices = [ for pickler in pickle, cPickle
(pickle, pickle, 0), for unpickler in pickle, cPickle
(pickle, pickle, 1), for proto in range(3)]
(pickle, pickle, 2), assert len(pickle_choices) == 2*2*3
(cPickle, cPickle, 0),
(cPickle, cPickle, 1),
(cPickle, cPickle, 2),
(pickle, cPickle, 0),
(pickle, cPickle, 1),
(pickle, cPickle, 2),
(cPickle, pickle, 0),
(cPickle, pickle, 1),
(cPickle, pickle, 2),
]
# XXX The test suite uncovered a bug in Python 2.2.2: if x and y are # XXX The test suite uncovered a bug in Python 2.2.2: if x and y are
# XXX instances of new-style classes (like date and time) that both # XXX instances of new-style classes (like date and time) that both
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment