From 29d907193dd0a58ab31b8d8f6dc50962eb731bda Mon Sep 17 00:00:00 2001 From: Matthijs van der Burgh Date: Sat, 13 Feb 2021 13:52:58 +0100 Subject: [PATCH] (robot_skills) don't use custom self --- robot_skills/src/robot_skills/mockbot.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/robot_skills/src/robot_skills/mockbot.py b/robot_skills/src/robot_skills/mockbot.py index 1e2ffaf344..a5b055145b 100755 --- a/robot_skills/src/robot_skills/mockbot.py +++ b/robot_skills/src/robot_skills/mockbot.py @@ -47,14 +47,13 @@ def old_query(spec, choices, timeout=10): class AlteredMagicMock(mock.MagicMock): - def assert_called_with(_mock_self, *args, **kwargs): + def assert_called_with(self, *args, **kwargs): """ Assert that the mock was called with the specified arguments. Raises an AssertionError if the args and keyword args passed in are different to the last call to the mock. """ - self = _mock_self if self.call_args is None: expected = self._format_mock_call_signature(args, kwargs) raise AssertionError('Expected call: %s\nNot called' % (expected,))