Sha256: 1a4e90de44b4a620ad003788f56322ad1d76b5a667ab0c67a6e5e4aa1510fb77
Contents?: true
Size: 1.5 KB
Versions: 2
Compression:
Stored size: 1.5 KB
Contents
module Fog module Storage class AzureRM # This class provides the actual implementation for service calls. class Real def list_containers(options = {}) msg = "Listing containers." Fog::Logger.debug msg begin containers = @blob_client.list_containers(options) rescue Azure::Core::Http::HTTPError => ex raise_azure_exception(ex, msg) end Fog::Logger.debug 'Listing containers successfully.' containers end end # This class provides the mock implementation for unit tests. class Mock def list_containers(*) [ { 'name' => 'testcontainer1', 'properties' => { 'last_modified' => 'Mon, 04 Jul 2016 02:50:20 GMT', 'etag' => '0x8D3A3B5F017F52D', 'lease_status' => 'unlocked', 'lease_state' => 'available' }, 'metadata' => {} }, { 'name' => 'testcontainer2', 'properties' => { 'last_modified' => 'Tue, 04 Aug 2015 06:01:08 GMT', 'etag' => '0x8D29C92176C8352', 'lease_status' => 'unlocked', 'lease_state' => 'available' }, 'metadata' => {} } ] end end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
fog-azure-rm-0.0.6 | lib/fog/azurerm/requests/storage/list_containers.rb |
fog-azure-rm-0.0.5 | lib/fog/azurerm/requests/storage/list_containers.rb |