Sha256: 5d77414cecb6a3b4818e2355488f3ce9408422645f28efcbb9df3e6b92224342

Contents?: true

Size: 1.17 KB

Versions: 47

Compression:

Stored size: 1.17 KB

Contents

module ApiStub
  module Models
    module Network
      # Mock class for Network Security Rule Model
      class NetworkSecurityRule
        def self.create_network_security_rule_response(network_client)
          nsr = '{
              "name":"myNsRule",
              "id":"/subscriptions/{guid}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/networkSecurityGroups/myNsg/securityRules/myNsRule",
              "etag":"W/\"00000000-0000-0000-0000-000000000000\"",
              "properties":{
                "provisioningState":"Succeeded",
                "description":"description-of-this-rule",
                "protocol": "*",
                "sourcePortRange":"source-port-range",
                "destinationPortRange":"destination-port-range",
                "sourceAddressPrefix":"*",
                "destinationAddressPrefix":"*",
                "access":"Allow",
                "priority":6500,
                "direction":"Inbound"
              }
          }'
          nsr_mapper = Azure::ARM::Network::Models::SecurityRule.mapper
          network_client.deserialize(nsr_mapper, Fog::JSON.decode(nsr), 'result.body')
        end
      end
    end
  end
end

Version data entries

47 entries across 47 versions & 4 rubygems

Version Path
fog-azure-rm-0.4.1 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.4.0 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.3.9 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.3.8 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.3.7 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.3.6 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.3.5 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.3.4 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-temp-0.0.4 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-temp-0.0.3 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.3.3 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-temp-0.0.2 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-temp-0.0.1 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.3.2 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-downgraded-0.3.1 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.3.1 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-downgraded-0.3.0 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.3.0 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.2.7 test/api_stub/models/network/network_security_rule.rb
fog-azure-rm-0.2.6 test/api_stub/models/network/network_security_rule.rb