Lines Matching defs:call
14 'call',
631 method call:
824 def _format_mock_failure_message(self, args, kwargs, action='call'):
834 * If call objects are asserted against a method/function like obj.meth1
835 then there could be no name for the call object to lookup. Hence just
867 Given a call (or simply an (args, kwargs) tuple), return a
886 return call(name, bound_call.args, bound_call.kwargs)
921 """assert that the last call was made with the specified arguments.
924 different to the last call to the mock."""
928 error_message = ('expected call not found.\nExpected: %s\nActual: %s'
943 """assert that the mock was called exactly once and that that call was
993 '%r does not contain all of %r in its call list, '
1004 the call is the most recent one."""
1011 '%s call not found' % expected_string
1056 Example: "\nCalls: [call(1), call(2)]."
1070 """A list which checks if it contains a call which may have an
1096 # but this will blow up on first call - so maybe we should fail early?
1135 # needs to be set here so assertions on call arguments pass before
1178 # executed separately from their call, also AsyncMock overrides this method
1229 If `side_effect` is an iterable then each call to the mock will return
1243 calling the Mock will pass the call through to the wrapped object
1543 # XXXX If new is a Mock we could call new.configure_mock(**kwargs)
1648 """Perform multiple patches in a single call. It takes the object to be
2393 recognized as an async function, and the result of a call is an awaitable:
2466 A tuple for holding the results of a call to a mock, either in the form
2469 If args or kwargs are empty then a call tuple will compare equal to
2476 The `_Call` object provides a useful shortcut for comparing with call::
2478 _Call(((1, 2), {'a': 3})) == call(1, 2, a=3)
2479 _Call(('foo', (1, 2), {'a': 3})) == call.foo(1, 2, a=3)
2617 name = self._mock_name or 'call'
2619 name = 'call%s' % name
2623 name = 'call'
2628 name = 'call'
2630 name = 'call.%s' % name
2632 name = 'call%s' % name
2637 """For a call object that represents multiple calls, `call_list`
2639 final call."""
2649 call = _Call(from_kall=False)