Sha256: 88f64398116aadd5121aeb5c9307a19f3334069689f6a8458ee008c8c6980112
Contents?: true
Size: 882 Bytes
Versions: 19
Compression:
Stored size: 882 Bytes
Contents
require "spec_helper" describe ApiClient::Connection::Oauth do it "adds basic middlewares to faraday" do instance = ApiClient::Connection::Oauth.new("http://google.com") instance.handler.builder.handlers.collect(&:name).should == [ "ApiClient::Connection::Middlewares::Request::OAuth", "Faraday::Request::UrlEncoded", "Faraday::Adapter::NetHttp" ] end it "adds the logger middlewares to faraday if ApiClient.logger is available" do logger = mock ApiClient.stub(:logger).and_return(logger) instance = ApiClient::Connection::Oauth.new("http://google.com") instance.handler.builder.handlers.collect(&:name).should == [ "ApiClient::Connection::Middlewares::Request::Logger", "ApiClient::Connection::Middlewares::Request::OAuth", "Faraday::Request::UrlEncoded", "Faraday::Adapter::NetHttp" ] end end
Version data entries
19 entries across 19 versions & 1 rubygems