Commit fdc3d3c8 authored by Vitja Makarov's avatar Vitja Makarov

Run uninitialized test in both cpython and cython

parent d8ffa16c
...@@ -76,7 +76,6 @@ def deleted(cond): ...@@ -76,7 +76,6 @@ def deleted(cond):
def test_nested(cond): def test_nested(cond):
""" """
>>> test_nested(True) >>> test_nested(True)
<built-in function a>
>>> test_nested(False) >>> test_nested(False)
Traceback (most recent call last): Traceback (most recent call last):
... ...
...@@ -85,7 +84,7 @@ def test_nested(cond): ...@@ -85,7 +84,7 @@ def test_nested(cond):
if cond: if cond:
def a(): def a():
pass pass
return a return a()
def test_outer(cond): def test_outer(cond):
""" """
...@@ -109,7 +108,7 @@ def test_inner(cond): ...@@ -109,7 +108,7 @@ def test_inner(cond):
>>> test_inner(False) >>> test_inner(False)
Traceback (most recent call last): Traceback (most recent call last):
... ...
UnboundLocalError: local variable 'a' referenced before assignment NameError: free variable 'a' referenced before assignment in enclosing scope
""" """
if cond: if cond:
a = {} a = {}
...@@ -120,7 +119,7 @@ def test_inner(cond): ...@@ -120,7 +119,7 @@ def test_inner(cond):
def test_class(cond): def test_class(cond):
""" """
>>> test_class(True) #doctest: +ELLIPSIS >>> test_class(True) #doctest: +ELLIPSIS
<class uninitialized.A at 0x...> <class ...A at 0x...>
>>> test_class(False) >>> test_class(False)
Traceback (most recent call last): Traceback (most recent call last):
... ...
......
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