'Configure log to capture test logs include selenium logs.
This allows us to attach them if test will be broken.'

def _configure_log(self):

    ROOT_LOGGER.handlers[:] = []
    self._log_buffer = StringIO()
    stream_handler = logging.StreamHandler(stream=self._log_buffer)
    stream_handler.setLevel(logging.DEBUG)
    formatter = logging.Formatter('%(asctime)s    -    %(name)s    -    %(levelname)s    -    %(message)s')
    stream_handler.setFormatter(formatter)
    ROOT_LOGGER.addHandler(stream_handler)
