Sha256: b48b0cad61ae1fbd6dbf0063411799ab772003cba32b8c9c5a799285b41150a8

Contents?: true

Size: 1.86 KB

Versions: 47

Compression:

Stored size: 1.86 KB

Contents

module Fog
  module Network
    class AzureRM
      # Real class for Network Request
      class Real
        def list_express_route_circuits(resource_group_name)
          msg = "Getting list of Express Route Circuits from Resource Group #{resource_group_name}."
          Fog::Logger.debug msg
          begin
            @network_client.express_route_circuits.list(resource_group_name)
          rescue MsRestAzure::AzureOperationError => e
            raise_azure_exception(e, msg)
          end
        end
      end

      # Mock class for Network Request
      class Mock
        def list_express_route_circuits(*)
          [
            {
              'name' => 'testCircuit',
              'id' => '/subscriptions/########-####-####-####-############/resourceGroup/resource_group_name/providers/Microsoft.Network/expressRouteCircuits/circuitName',
              'etag' => 'W/\"00000000-0000-0000-0000-000000000000\"',
              'location' => 'eastus',
              'tags' => {
                'key1' => 'value1',
                'key2' => 'value2'
              },
              'sku' => {
                'name' => 'Standard_MeteredData',
                'tier' => 'Standard',
                'family' => 'MeteredData'
              },
              'properties' => {
                'provisioningState' => 'Succeeded',
                'circuitProvisioningState' => 'Enabled',
                'serviceProviderProvisioningState' => 'Provisioned',
                'serviceProviderProperties' => {
                  'serviceProviderName' => 'Telenor',
                  'peeringLocation' => 'London',
                  'bandwidthInMbps' => 100
                }
              },
              'serviceKey' => '<unique service key for circuit>',
              'serviceProviderNotes' => '<notes set only by ServiceProvider>'
            }
          ]
        end
      end
    end
  end
end

Version data entries

47 entries across 47 versions & 4 rubygems

Version Path
fog-azure-rm-0.2.5 lib/fog/azurerm/requests/network/list_express_route_circuits.rb
fog-azure-rm-0.2.4 lib/fog/azurerm/requests/network/list_express_route_circuits.rb
fog-azure-rm-0.2.3 lib/fog/azurerm/requests/network/list_express_route_circuits.rb
fog-azure-rm-0.2.2 lib/fog/azurerm/requests/network/list_express_route_circuits.rb
fog-azure-rm-0.2.1 lib/fog/azurerm/requests/network/list_express_route_circuits.rb
fog-azure-rm-0.2.0 lib/fog/azurerm/requests/network/list_express_route_circuits.rb
fog-azure-rm-0.1.2 lib/fog/azurerm/requests/network/list_express_route_circuits.rb