summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Belopolsky <alexander.belopolsky@gmail.com>2010-06-23 22:29:48 (GMT)
committerAlexander Belopolsky <alexander.belopolsky@gmail.com>2010-06-23 22:29:48 (GMT)
commit33b94c9fa9f10405cf52e825d71c9ffda7edc186 (patch)
tree9b1351fe076268d5dad47815cbcd3f08945e632e
parent1b7046b99e2369175c19532a788e722daf7c65f0 (diff)
downloadcpython-33b94c9fa9f10405cf52e825d71c9ffda7edc186.zip
cpython-33b94c9fa9f10405cf52e825d71c9ffda7edc186.tar.gz
cpython-33b94c9fa9f10405cf52e825d71c9ffda7edc186.tar.bz2
Test future pickle protocols. Thanks Antoine Pitrou for suggestion.
-rw-r--r--Lib/test/test_datetime.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/Lib/test/test_datetime.py b/Lib/test/test_datetime.py
index 7048a11..f1b4ecf 100644
--- a/Lib/test/test_datetime.py
+++ b/Lib/test/test_datetime.py
@@ -19,8 +19,9 @@ from datetime import timezone
from datetime import date, datetime
import time as _time
-pickle_choices = [(pickle, pickle, proto) for proto in range(4)]
-assert len(pickle_choices) == 4
+pickle_choices = [(pickle, pickle, proto)
+ for proto in range(pickle.HIGHEST_PROTOCOL + 1)]
+assert len(pickle_choices) == pickle.HIGHEST_PROTOCOL + 1
# An arbitrary collection of objects of non-datetime types, for testing
# mixed-type comparisons.