lib/fog/azurerm/requests/network/delete_public_ip.rb in fog-azure-rm-0.0.1 vs lib/fog/azurerm/requests/network/delete_public_ip.rb in fog-azure-rm-0.0.2
- old
+ new
@@ -7,20 +7,22 @@
Fog::Logger.debug "Deleting PublicIP #{name} from Resource Group #{resource_group}."
begin
promise = @network_client.public_ipaddresses.delete(resource_group, name)
response = promise.value!
Fog::Logger.debug "PublicIP #{name} Deleted Successfully."
- response
+ true
rescue MsRestAzure::AzureOperationError => e
msg = "Exception deleting Public IP #{name} in Resource Group: #{resource_group}. #{e.body['error']['message']}"
raise msg
end
end
end
# Mock class for Network Request
class Mock
- def delete_public_ip(_resource_group, _name)
+ def delete_public_ip(resource_group, name)
+ Fog::Logger.debug "Public IP #{name} from Resource group #{resource_group} deleted successfully."
+ return true
end
end
end
end
end