Commit ba02026a authored by Stefan Behnel's avatar Stefan Behnel

Py2.6 test fixes

parent d85651f2
...@@ -85,11 +85,11 @@ __doc__ = u""" ...@@ -85,11 +85,11 @@ __doc__ = u"""
""" """
import sys, re import sys, re
if sys.version_info[0] >= 3: if sys.version_info >= (2,6):
__doc__ = re.sub(u"Error: (.*)exactly(.*)", u"Error: \\1at most\\2", __doc__) __doc__ = re.sub(u"Error: (.*)exactly(.*)", u"Error: \\1at most\\2", __doc__)
import sys, re import sys, re
if sys.version_info[0] >= 3: if sys.version_info >= (2,6):
__doc__ = re.sub(u"(ELLIPSIS[^>]*Error: )[^\n]*\n", u"\\1...\n", __doc__, re.M) __doc__ = re.sub(u"(ELLIPSIS[^>]*Error: )[^\n]*\n", u"\\1...\n", __doc__, re.M)
class Spam: class Spam:
......
...@@ -85,7 +85,7 @@ __doc__ = u""" ...@@ -85,7 +85,7 @@ __doc__ = u"""
""" """
import sys, re import sys, re
if sys.version_info[0] >= 3: if sys.version_info >= (2,6):
__doc__ = re.sub(u"Error: (.*)exactly(.*)", u"Error: \\1at most\\2", __doc__) __doc__ = re.sub(u"Error: (.*)exactly(.*)", u"Error: \\1at most\\2", __doc__)
cdef class Ext: cdef class Ext:
......
...@@ -89,11 +89,11 @@ __doc__ = u""" ...@@ -89,11 +89,11 @@ __doc__ = u"""
""" """
import sys, re import sys, re
if sys.version_info[0] >= 3: if sys.version_info >= (2,6):
__doc__ = re.sub(u"Error: (.*)exactly(.*)", u"Error: \\1at most\\2", __doc__) __doc__ = re.sub(u"Error: (.*)exactly(.*)", u"Error: \\1at most\\2", __doc__)
import sys, re import sys, re
if sys.version_info[0] >= 3: if sys.version_info >= (2,6):
__doc__ = re.sub(u"(ELLIPSIS[^>]*Error: )[^\n]*\n", u"\\1...\n", __doc__, re.M) __doc__ = re.sub(u"(ELLIPSIS[^>]*Error: )[^\n]*\n", u"\\1...\n", __doc__, re.M)
cdef sorteditems(d): cdef sorteditems(d):
......
...@@ -82,7 +82,7 @@ __doc__ = u""" ...@@ -82,7 +82,7 @@ __doc__ = u"""
""" """
import sys, re import sys, re
if sys.version_info[0] >= 3: if sys.version_info >= (2,6):
__doc__ = re.sub(u"Error: (.*)exactly(.*)", u"Error: \\1at most\\2", __doc__) __doc__ = re.sub(u"Error: (.*)exactly(.*)", u"Error: \\1at most\\2", __doc__)
def b(a, b, c): def b(a, b, c):
......
...@@ -82,7 +82,7 @@ __doc__ = u""" ...@@ -82,7 +82,7 @@ __doc__ = u"""
""" """
import sys, re import sys, re
if sys.version_info[0] >= 3: if sys.version_info >= (2,6):
__doc__ = re.sub(u"Error: (.*)exactly(.*)", u"Error: \\1at most\\2", __doc__) __doc__ = re.sub(u"Error: (.*)exactly(.*)", u"Error: \\1at most\\2", __doc__)
# the calls: # the calls:
......
__doc__ = u""" __doc__ = u"""# Python 3 gets all of these right ...
>>> f.__doc__ >>> f.__doc__
'This is a function docstring.' 'This is a function docstring.'
......
...@@ -5,7 +5,7 @@ __doc__ = u""" ...@@ -5,7 +5,7 @@ __doc__ = u"""
""" """
import sys, re import sys, re
if sys.version_info[0] >= 3: if sys.version_info >= (2,6):
__doc__ = re.sub(u"Error: .*", u"Error: ...", __doc__) __doc__ = re.sub(u"Error: .*", u"Error: ...", __doc__)
cdef class Spam: cdef class Spam:
......
...@@ -14,7 +14,7 @@ __doc__ = u""" ...@@ -14,7 +14,7 @@ __doc__ = u"""
""" """
import sys, re import sys, re
if sys.version_info[0] >= 3: if sys.version_info >= (2,6):
__doc__ = re.sub(u"Error: .*exactly.*", u"Error: ...", __doc__) __doc__ = re.sub(u"Error: .*exactly.*", u"Error: ...", __doc__)
import sys import sys
......
...@@ -85,11 +85,11 @@ __doc__ = u""" ...@@ -85,11 +85,11 @@ __doc__ = u"""
""" """
import sys, re import sys, re
if sys.version_info[0] >= 3: if sys.version_info >= (2,6):
__doc__ = re.sub(u"Error: (.*)exactly(.*)", u"Error: \\1at most\\2", __doc__) __doc__ = re.sub(u"Error: (.*)exactly(.*)", u"Error: \\1at most\\2", __doc__)
import sys, re import sys, re
if sys.version_info[0] >= 3: if sys.version_info >= (2,6):
__doc__ = re.sub(u"(ELLIPSIS[^>]*Error: )[^\n]*\n", u"\\1...\n", __doc__, re.M) __doc__ = re.sub(u"(ELLIPSIS[^>]*Error: )[^\n]*\n", u"\\1...\n", __doc__, re.M)
cdef sorteditems(d): cdef sorteditems(d):
......
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