Sha256: 493f45920aa9f21b21f39300499e8ef5779ca6eb6eb8d113f244167e667361fe

Contents?: true

Size: 419 Bytes

Versions: 30

Compression:

Stored size: 419 Bytes

Contents

require File.dirname(__FILE__) + '/base'

describe RestClient::RawResponse do
	before do
		@tf = mock("Tempfile", :read => "the answer is 42", :open => true)
		@net_http_res = mock('net http response')
		@response = RestClient::RawResponse.new(@tf, @net_http_res)
	end

	it "behaves like string" do
		@response.to_s.should == 'the answer is 42'
	end

	it "exposes a Tempfile" do
		@response.file.should == @tf
	end
end

Version data entries

30 entries across 30 versions & 10 rubygems

Version Path
adamwiggins-rest-client-1.0.2 spec/raw_response_spec.rb
adamwiggins-rest-client-1.0.3 spec/raw_response_spec.rb
adamwiggins-rest-client-1.0.4 spec/raw_response_spec.rb
auser-poolparty-1.2.10 vendor/gems/rest-client/spec/raw_response_spec.rb
auser-poolparty-1.2.3 vendor/gems/rest-client/spec/raw_response_spec.rb
auser-poolparty-1.2.4 vendor/gems/rest-client/spec/raw_response_spec.rb
auser-poolparty-1.2.7 vendor/gems/rest-client/spec/raw_response_spec.rb
auser-poolparty-1.2.8 vendor/gems/rest-client/spec/raw_response_spec.rb
auser-poolparty-1.2.9 vendor/gems/rest-client/spec/raw_response_spec.rb
benschwarz-smoke-0.5.0 vendor/rest-client/spec/raw_response_spec.rb
benschwarz-smoke-0.5.1 vendor/rest-client/spec/raw_response_spec.rb
benschwarz-smoke-0.5.2 vendor/rest-client-1.0.1/spec/raw_response_spec.rb
benschwarz-smoke-0.5.3 vendor/rest-client-1.0.1/spec/raw_response_spec.rb
benschwarz-smoke-0.5.4 vendor/rest-client-1.0.1/spec/raw_response_spec.rb
benschwarz-smoke-0.5.5 vendor/rest-client-1.0.1/spec/raw_response_spec.rb
benschwarz-smoke-0.5.6 vendor/rest-client-1.0.1/spec/raw_response_spec.rb
benschwarz-smoke-0.5.7 vendor/gems/gems/rest-client-1.0.1/spec/raw_response_spec.rb
francois-rest-client-1.1.5 spec/raw_response_spec.rb
francois-rest-client-1.1.6 spec/raw_response_spec.rb
sml-rest-client-1.1.7 spec/raw_response_spec.rb