test/api_stub/models/network/network_interface.rb in fog-azure-rm-0.0.4 vs test/api_stub/models/network/network_interface.rb in fog-azure-rm-0.0.5
- old
+ new
@@ -1,10 +1,10 @@
module ApiStub
module Models
module Network
class NetworkInterface
- def self.create_network_interface_response
+ def self.create_network_interface_response(network_client)
nic = '{
"name":"fog-test-network-interface",
"id":"/subscriptions/{guid}/resourceGroups/fog-test-rg/providers/Microsoft.Network/networkInterfaces/fog-test-network-interface",
"location":"West US",
"tags":{
@@ -61,10 +61,11 @@
"internalDnsNameLabel": "IdnsVm1",
"internalFqd": "IdnsVm1.a2ftlxfjn2iezihj3udx1wfn4d.hx.internal.cloudapp.net"
}
}
}'
- JSON.parse(nic)
+ network_interface_mapper = Azure::ARM::Network::Models::NetworkInterface.mapper
+ network_client.deserialize(network_interface_mapper, JSON.load(nic), 'result.body')
end
end
end
end
end