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

Method _calls_repr

Lib/unittest/mock.py:1099–1109  ·  view source on GitHub ↗

Renders self.mock_calls as a string. Example: "\nCalls: [call(1), call(2)]." If self.mock_calls is empty, an empty string is returned. The output will be truncated if very long.

(self)

Source from the content-addressed store, hash-verified

1097
1098
1099 def _calls_repr(self):
1100 """Renders self.mock_calls as a string.
1101
1102 Example: "\nCalls: [call(1), call(2)]."
1103
1104 If self.mock_calls is empty, an empty string is returned. The
1105 output will be truncated if very long.
1106 """
1107 if not self.mock_calls:
1108 return ""
1109 return f"\nCalls: {safe_repr(self.mock_calls)}."
1110
1111
1112# Denylist for forbidden attribute names in safe mode

Callers 3

assert_not_calledMethod · 0.95
assert_called_onceMethod · 0.95

Calls 1

safe_reprFunction · 0.90

Tested by

no test coverage detected