Commit cd8f7608 authored by Stefan Behnel's avatar Stefan Behnel

Py2.7 test fixes

parent b60d65e2
......@@ -22,13 +22,13 @@ def test(dict d, index):
...
ValueError
>>> test(None, 1)
>>> test(None, 1) # doctest: +ELLIPSIS
Traceback (most recent call last):
...
TypeError: 'NoneType' object is unsubscriptable
TypeError: 'NoneType' object is ...
"""
return d[index]
cdef class Subscriptable:
def __getitem__(self, key):
return key
\ No newline at end of file
return key
......@@ -6,7 +6,7 @@ __doc__ = u"""
"""
import sys
if sys.version_info[0] >= 3:
if sys.version_info >= (2,7):
__doc__ = __doc__.replace(u'is unsubscriptable', u'is not subscriptable')
elif sys.version_info < (2,5):
__doc__ = __doc__.replace(u"'int' object is unsubscriptable", u'unsubscriptable object')
......
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