Sha256: 67bf9958b58c3d33754b989466e735e2c42532db8bf0080da889e095a3c99c93
Contents?: true
Size: 724 Bytes
Versions: 2
Compression:
Stored size: 724 Bytes
Contents
require 'spec_helper' describe Bearychat::Notifier::HttpClient do describe ".post" do it "initialize HttpClient with the given uri and params then call" do http_post_double = instance_double("Bearychat::Notifier::HttpClient") expect( described_class ).to receive(:new) .with('uri', 'params') .and_return( http_post_double ) expect( http_post_double ).to receive( :call ) described_class.post 'uri', 'params' end end describe "#initialize" do it "setting options HttpClient" do http_client = described_class.new('http://example.com/', http_options: { open_timeout: 5 }) http_client.call end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
bearychat-notifier-0.0.6 | spec/lib/bearychat-notifier/http_client_spec.rb |
bearychat-notifier-0.0.5 | spec/lib/bearychat-notifier/http_client_spec.rb |