code: def save_all_webdriver_logs(cls, test_name, test_passed):
          
          log_name = '{} [driver {}]' if len(cls.driver_wrappers) > 1 else '{}'
          driver_index = 1
          for driver_wrapper in cls.driver_wrappers:
              if not driver_wrapper.driver or driver_wrapper.server_type in ['ggr', 'selenoid']:
                  continue
              if driver_wrapper.config.getboolean_optional('Server', 'logs_enabled') or not test_passed:
                  try:
                      driver_wrapper.utils.save_webdriver_logs(log_name.format(test_name, driver_index))
                  except Exception as exc:
                      # Capture exceptions to avoid errors in teardown method due to session timeouts
                      driver_wrapper.logger.warn('Error downloading webdriver logs: %s' % exc)
              driver_index += 1
docs: Get all webdriver logs of each driver and write them to log files
  
          :param test_name: test that has generated these logs
          :param test_passed: True if the test has passed