@JunitTestCase()
def generate_and_download_image(self, iso_download_path=None, static_network_config=None, iso_image_type=None, ssh_key=None):
    warnings.warn('generate_and_download_image is deprecated. Use generate_and_download_infra_env instead.', DeprecationWarning)
    iso_download_path = (iso_download_path or self._config.iso_download_path)
    if (not os.path.exists(iso_download_path)):
        utils.recreate_folder(os.path.dirname(iso_download_path), force_recreate=False)
    self.api_client.generate_and_download_image(cluster_id=self.id, ssh_key=(ssh_key or self._config.ssh_public_key), image_path=iso_download_path, image_type=(iso_image_type or self._config.iso_image_type), static_network_config=static_network_config)
@JunitTestCase()
def generate_and_download_image(self, iso_download_path=None, static_network_config=None, iso_image_type=None, ssh_key=None):
    warnings.warn('generate_and_download_image is deprecated. Use generate_and_download_infra_env instead.', DeprecationWarning)
    iso_download_path = (iso_download_path or self._config.iso_download_path)
    if (not os.path.exists(iso_download_path)):
        utils.recreate_folder(os.path.dirname(iso_download_path), force_recreate=False)
    self.api_client.generate_and_download_image(cluster_id=self.id, ssh_key=(ssh_key or self._config.ssh_public_key), image_path=iso_download_path, image_type=(iso_image_type or self._config.iso_image_type), static_network_config=static_network_config)