def last_call(self, method=None):
        if not self.calls:
            return None
        elif method is None:
            return self.calls[-1]
        else:
            try:
                return next(call for call in reversed(self.calls)
                            if call[0] == method)
            except StopIteration:
                return None
Close a cursor by killing it in a batch.
dataset/ETHPy150Open home-assistant/home-assistant/tests/common.py/MockToggleDevice.last_call--crossover with--dataset/ETHPy150Open blynch/CloudMemeBackend/pymongo/cursor_manager.py/BatchCursorManager.close