MCPcopy
hub / github.com/igrek51/wat / test_inspect_function

Function test_inspect_function

tests/inspection/test_inspect.py:91–109  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

89
90
91def test_inspect_function():
92 def foo(a: int, b: str = 'bar') -> str:
93 """
94 Do something
95 dumb
96 """
97 return a * b
98
99 output = inspect_format(foo)
100 print(output)
101 assert_multiline_match(output, r'''
102value: <function test_inspect_function\.<locals>\.foo at .*>
103type: function
104signature: def foo\(a: int, b: str = 'bar'\) -> str
105"""
106Do something
107dumb
108"""
109''&#x27;)
110
111
112def test_inspect_nested_dict():

Callers

nothing calls this directly

Calls 2

inspect_formatFunction · 0.90
assert_multiline_matchFunction · 0.90

Tested by

no test coverage detected