Set the event loop.

def set_event_loop(self, event_loop):
        """Set the event loop."""
        assert event_loop is None or isinstance(event_loop, AbstractEventLoop)
        self._event_loop = event_loop