- Notifications
You must be signed in to change notification settings - Fork749
Closed
Description
Environment
- Pythonnet version: 2.5.0
- Python version: 3.7
- Operating System: Windows 10
Details
namespacePython.Test{publicclassMethodArityTest{publicstringFoo(inta){return"Arity 1";}publicstringFoo(inta,intb){return"Arity 2";}}}
deftest_keyword_arg_method_resolution():"""Test correct method is chosen using keyword arguments"""fromPython.TestimportMethodArityTestob=MethodArityTest()assertob.Foo(1,b=2)=="Arity 2"
The test above fails with:
def test_keyword_arg_method_resolution(): """Test correct method is chosen using keyword arguments""" from Python.Test import MethodArityTest ob = MethodArityTest()> assert ob.Foo(1, b=2) == "Arity 2"E AssertionError: assert 'Arity 1' == 'Arity 2'E - Arity 1E ? ^E + Arity 2E ? ^
Metadata
Metadata
Assignees
Labels
No labels