search for: api_host

Displaying 2 results from an estimated 2 matches for "api_host".

Did you mean: a_host
2008 Jan 31
1
RSpec and the Basecamp API
...a basic question but I''m new to rspec and still trying to work out how to do things. I''m working on a rails project that requires basecamp integration via the api, which is fairly trivial to use via the basecamp.rb wrapper: Connection: basecamp = Basecamp.new(APP_CONFIG[''api_host''], APP_CONFIG[''api_username''], APP_CONFIG[''api_pwd'']) And to retrieve a list of Projects: puts "Projects: #{basecamp.projects}" I know how to make this work in the model, I''m just having trouble working out how to create a usable mo...
2013 Jan 29
0
How to stub a class inside a module with Mocha in Ruby?
...}) @consumer_key = options[:consumer_key] @consumer_secret = options[:consumer_secret] @token = options[:token] @secret = options[:secret] @proxy = options[:proxy] @debug = options[:debug] @api_version = options[:api_version] || ''1'' @api_host = options[:api_host] || ''api.twitter.com'' @search_host = options[:search_host] || ''search.twitter.com'' end ... def request_token(options={}) consumer(:secure => true).get_request_token(options) end end The request_token is the meth...