Commit 28f5f26b authored by Stefan Behnel's avatar Stefan Behnel

Restore Py2 compatibility in test.

parent a68109c0
......@@ -7,22 +7,27 @@ print(end='') # test that language_level 3 applies immediately at the module st
cimport cython
__doc__ = """
>>> items = sorted(locals_function(1).items())
>>> for item in items:
... print('%s = %r' % item)
a = 1
b = 2
x = u'abc'
>>> except_as_deletes
True
>>> no_match_does_not_touch_target
True
"""
import sys
IS_PY2 = sys.version_info[0] < 3
if not IS_PY2:
__doc__ = __doc__.replace(" u'", " '")
def locals_function(a, b=2):
"""
>>> items = sorted(locals_function(1).items())
>>> for item in items:
... print('%s = %r' % item)
a = 1
b = 2
x = 'abc'
"""
x = 'abc'
return locals()
......
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