Sha256: 2f56e96240f5f899e1ee621d6f627e5276ec25986d136177ec3c98c544c55d6f
Contents?: true
Size: 687 Bytes
Versions: 54
Compression:
Stored size: 687 Bytes
Contents
class Ey::Core::Client class Real def get_server_usages(params={}) account_id = params["account_id"] billing_month = params.fetch("billing_month", Date.today.strftime("%Y-%m")) request( :path => "accounts/#{account_id}/server-usages/#{billing_month}" ) end end # Real class Mock def get_server_usages(params={}) account_id = params["account_id"] billing_month = params.fetch("billing_month", Date.today.strftime("%Y-%m")) response( :body => { "server_usages" => self.find(:server_usages, account_id)[billing_month] || [] }, :status => 200, ) end end # Mock end # Ey::Core::Client
Version data entries
54 entries across 54 versions & 3 rubygems