Sha256: 9aabfac5b32faf10b8dd80bceb141173c999a0c56a22bbf5b22d7a1e53ab3dd6
Contents?: true
Size: 1.07 KB
Versions: 48
Compression:
Stored size: 1.07 KB
Contents
module Fog module Storage class AzureRM # This class provides the actual implementation for service calls. class Real # Delete a disk in Azure storage. # # @param disk_name [String] Name of disk # @param options [Hash] # @option options [String] container_name Sets name of the container which contains the disk. Default is 'vhds'. # # @return [Boolean] # def delete_disk(disk_name, options = {}) msg = "Deleting disk(#{disk_name}). options: #{options}" Fog::Logger.debug msg container_name = options.delete(:container_name) container_name = 'vhds' if container_name.nil? delete_blob(container_name, "#{disk_name}.vhd") Fog::Logger.debug "Successfully deleted Disk: #{disk_name}." true end end # This class provides the mock implementation for unit tests. class Mock def delete_disk(*) Fog::Logger.debug 'Successfully deleted Disk' true end end end end end
Version data entries
48 entries across 48 versions & 5 rubygems