Sha256: eb562f07748b423b8f0fac0050049688d154e129d7192eda4133316c994eb98c
Contents?: true
Size: 757 Bytes
Versions: 29
Compression:
Stored size: 757 Bytes
Contents
module Fog module HP class Network class Real # Delete an existing port # # ==== Parameters # * port_id<~String> - UUId for the port to delete def delete_port(port_id) request( :expects => 204, :method => 'DELETE', :path => "ports/#{port_id}" ) end end class Mock def delete_port(port_id) response = Excon::Response.new if list_ports.body['ports'].find {|_| _['id'] == port_id} self.data[:ports].delete(port_id) response.status = 204 response else raise Fog::HP::Network::NotFound end end end end end end
Version data entries
29 entries across 29 versions & 4 rubygems