Create a new mock method call and return it. Args: # method name: the name of the method being called. method_name: str Returns: A new MockMethod aware of MockAnything's state (record or replay).
(self, method_name)
| 293 | return self._CreateMockMethod(method_name) |
| 294 | |
| 295 | def _CreateMockMethod(self, method_name): |
| 296 | """Create a new mock method call and return it. |
| 297 | |
| 298 | Args: |
| 299 | # method name: the name of the method being called. |
| 300 | method_name: str |
| 301 | |
| 302 | Returns: |
| 303 | A new MockMethod aware of MockAnything's state (record or replay). |
| 304 | """ |
| 305 | |
| 306 | return MockMethod(method_name, self._expected_calls_queue, |
| 307 | self._replay_mode) |
| 308 | |
| 309 | def __nonzero__(self): |
| 310 | """Return 1 for nonzero so the mock can be used as a conditional.""" |
no test coverage detected