MCPcopy Index your code
hub / github.com/RustPython/RustPython / _check_signature

Function _check_signature

Lib/unittest/mock.py:128–137  ·  view source on GitHub ↗
(func, mock, skipfirst, instance=False)

Source from the content-addressed store, hash-verified

126
127
128def _check_signature(func, mock, skipfirst, instance=False):
129 sig = _get_signature_object(func, instance, skipfirst)
130 if sig is None:
131 return
132 func, sig = sig
133 def checksig(self, /, *args, **kwargs):
134 sig.bind(*args, **kwargs)
135 _copy_func_details(func, checksig)
136 type(mock)._mock_check_sig = checksig
137 type(mock).__signature__ = sig
138
139
140def _copy_func_details(func, funcopy):

Callers 1

create_autospecFunction · 0.85

Calls 2

_get_signature_objectFunction · 0.85
_copy_func_detailsFunction · 0.85

Tested by

no test coverage detected