lib/fog/azurerm/dns.rb in fog-azure-rm-0.0.2 vs lib/fog/azurerm/dns.rb in fog-azure-rm-0.0.3

- old
+ new

@@ -1,10 +1,11 @@ require 'fog/azurerm/core' require 'fog/azurerm/credentials' module Fog module DNS + # This class registers models, requests and collections class AzureRM < Fog::Service requires :tenant_id requires :client_id requires :client_secret requires :subscription_id @@ -23,25 +24,28 @@ model :zone collection :zones model :record_set collection :record_sets + # This class provides the mock implementation for unit tests. class Mock - def initialize(options = {}) + def initialize(_options = {}) end end + # This class provides the actual implemention for service calls. class Real def initialize(options) @tenant_id = options[:tenant_id] @client_id = options[:client_id] @client_secret = options[:client_secret] @subscription_id = options[:subscription_id] @resources = Fog::Resources::AzureRM.new( - tenant_id: options[:tenant_id], - client_id: options[:client_id], - client_secret: options[:client_secret], - subscription_id: options[:subscription_id]) + tenant_id: options[:tenant_id], + client_id: options[:client_id], + client_secret: options[:client_secret], + subscription_id: options[:subscription_id] + ) end end end end end