Skip to content
This repository has been archived by the owner on May 31, 2020. It is now read-only.

Added test case for issue #861 #862

Merged
merged 1 commit into from
Jul 6, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions tests/structures/test_function.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
from unittest import expectedFailure

from ..utils import TranspileTestCase


Expand Down Expand Up @@ -238,6 +240,25 @@ def myfunc(value):
print("value =", myfunc(5))
""")

@expectedFailure
def test_redefine_nested_from_other_function(self):
self.assertCodeExecution("""
def func():
def nested_func():
print("Hello World from func")

nested_func()

def func2():
def nested_func():
print("Hello World from func2")

nested_func()

func()
func2()
""")

def test_noarg_unexpected_extra_arg(self):
self.assertCodeExecution("""
def myfunc():
Expand Down