Sha256: 12d8e2d7c6351e88a2e0f35fc5f0032faa7fefb1e5aba6395fb4acc056db9116
Contents?: true
Size: 505 Bytes
Versions: 2
Compression:
Stored size: 505 Bytes
Contents
require 'spec_helper' describe Http::Options, "response" do let(:opts){ Http::Options.new } it 'defaults to :auto' do opts.response.should eq(:auto) end it 'may be specified with with_response' do opts2 = opts.with_response(:body) opts.response.should eq(:auto) opts2.response.should eq(:body) end it 'recognizes invalid responses' do lambda{ opts.with_response(:not_a_valid_response) }.should raise_error(ArgumentError, /not_a_valid_response/) end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
http-0.3.0 | spec/http/options/response_spec.rb |
http-0.2.0 | spec/http/options/response_spec.rb |