Sha256: 5fc569d74e77381f749f7e5aed565a718f15a6f50a7fe359b9ba55f9f0ce00f1

Contents?: true

Size: 574 Bytes

Versions: 53

Compression:

Stored size: 574 Bytes

Contents

class Ey::Core::Client
  class Real
    def update_addon(params={})
      url = params.delete("url") or raise "URL needed"
      request(
        :method => :put,
        :url    => url,
        :params => params,
      )
    end
  end # Real

  class Mock
    def update_addon(params={})
      addon = params["addon"]

      extract_url_params!(params)

      find(:accounts, params["account"])

      resource = self.find(:addons, params["addon"])

      response(
        :body => {"addon" => resource.merge!(addon) },
      )
    end
  end # Mock
end # Ey::Core::Client

Version data entries

53 entries across 53 versions & 3 rubygems

Version Path
ey-core-3.6.4 lib/ey-core/requests/update_addon.rb
ey-core-3.6.3 lib/ey-core/requests/update_addon.rb
ey-core-3.6.1 lib/ey-core/requests/update_addon.rb
groove-ey-core-3.6.3 lib/ey-core/requests/update_addon.rb
groove-ey-core-3.6.2 lib/ey-core/requests/update_addon.rb
groove-ey-core-3.6.1 lib/ey-core/requests/update_addon.rb
ey-core-3.5.0 lib/ey-core/requests/update_addon.rb
ey-core-3.4.4 lib/ey-core/requests/update_addon.rb
ey-core-3.4.2 lib/ey-core/requests/update_addon.rb
ey-core-3.4.1 lib/ey-core/requests/update_addon.rb
ey-core-3.4.0 lib/ey-core/requests/update_addon.rb
ey-core-3.3.1 lib/ey-core/requests/update_addon.rb
ey-core-3.3.0 lib/ey-core/requests/update_addon.rb
ey-core-3.2.6 lib/ey-core/requests/update_addon.rb
ey-core-3.2.5 lib/ey-core/requests/update_addon.rb
ey-core-3.2.4 lib/ey-core/requests/update_addon.rb
ey-core-3.2.3 lib/ey-core/requests/update_addon.rb
ey-core-3.2.2 lib/ey-core/requests/update_addon.rb
ey-core-3.2.1 lib/ey-core/requests/update_addon.rb
ey-core-3.2.0 lib/ey-core/requests/update_addon.rb