MCPcopy
hub / github.com/pytest-dev/pytest / repr_callable

Function repr_callable

src/_pytest/raises.py:300–305  ·  view source on GitHub ↗

Get the repr of a ``check`` parameter. Split out so it can be monkeypatched (e.g. by hypothesis)

(fun: Callable[[BaseExcT_1], bool])

Source from the content-addressed store, hash-verified

298
299
300def repr_callable(fun: Callable[[BaseExcT_1], bool]) -> str:
301 """Get the repr of a ``check`` parameter.
302
303 Split out so it can be monkeypatched (e.g. by hypothesis)
304 """
305 return repr(fun)
306
307
308def backquote(s: str) -> str:

Callers 4

test_checkFunction · 0.90
_check_checkMethod · 0.85
__repr__Method · 0.85
__repr__Method · 0.85

Calls

no outgoing calls

Tested by 1

test_checkFunction · 0.72