Sha256: 2c810967bcf1c7c0200fdb3ca905038615479da2994d0aed4cd08d8337eebf6d
Contents?: true
Size: 965 Bytes
Versions: 53
Compression:
Stored size: 965 Bytes
Contents
class Ey::Core::Client class Real def create_keypair_deployment(params={}) url = params.delete("url") keypair_id = params["keypair"] environment_id = params["environment"] request( :method => :post, :path => "/environments/#{environment_id}/keypairs/#{keypair_id}", :url => url, ) end end # Real class Mock def create_keypair_deployment(params={}) resource_id = self.serial_id keypair_id = params["keypair"] environment_id = params["environment"] resource = { "id" => resource_id, "keypair" => url_for("/keypairs/#{keypair_id}"), "target" => url_for("/environments/#{environment_id}"), } self.data[:keypair_deployments][resource_id] = resource response( :body => {"keypair_deployment" => resource}, :status => 201, ) end end # Mock end # Ey::Core::Client
Version data entries
53 entries across 53 versions & 3 rubygems