

def test_raw_js(self):

    def func(a, b):
        '\n            var c = 3;\n            return a + b + c;\n            '
    code = py2js(func)
    assert (evaljs((code + 'func(100, 10)')) == '113')
    assert (evaljs((code + 'func("x", 10)')) == 'x103')

dataset/ETHPy150Open zoofIO/flexx/flexx/pyscript/tests/test_parser2.py TestFunctions.test_raw_js/original