MCPcopy Create free account
hub / github.com/ipython/ipython / test_nested_call

Function test_nested_call

IPython/utils/tests/test_tokenutil.py:75–88  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

73 expect_token(expected, cell, i)
74
75def test_nested_call():
76 cell = "foo(bar(a=5), b=10)"
77 expected = 'foo'
78 start = cell.index('bar') + 1
79 for i in range(start, start + 3):
80 expect_token(expected, cell, i)
81 expected = 'bar'
82 start = cell.index('a=')
83 for i in range(start, start + 3):
84 expect_token(expected, cell, i)
85 expected = 'foo'
86 start = cell.index(')') + 1
87 for i in range(start, len(cell)-1):
88 expect_token(expected, cell, i)
89
90def test_attrs():
91 cell = "a = obj.attr.subattr"

Callers

nothing calls this directly

Calls 1

expect_tokenFunction · 0.85

Tested by

no test coverage detected