spec/lib/curb-fu/request/test_spec.rb in curb-fu-0.4.4 vs spec/lib/curb-fu/request/test_spec.rb in curb-fu-0.6.0
- old
+ new
@@ -140,11 +140,11 @@
end
it 'should return a CurbFu::Response object' do
response = CurbFu::Request.get('http://a.example.com/gimme/html')
response.should be_a_kind_of(CurbFu::Response::Base)
response.status.should == 200
- response.headers.should == { 'Content-Type' => 'spec/testcase' }
+ response.headers.should == { 'Content-Type' => 'spec/testcase', "Content-Length"=>"39" }
response.body.should == "A is for Archer, an excellent typeface."
end
end
describe "post" do
@@ -160,11 +160,11 @@
end
it 'should return a CurbFu::Response object' do
response = CurbFu::Request.post('http://a.example.com/gimme/html')
response.should be_a_kind_of(CurbFu::Response::Base)
response.status.should == 200
- response.headers.should == { 'Content-Type' => 'spec/testcase' }
+ response.headers.should == { 'Content-Type' => 'spec/testcase', "Content-Length"=>"39" }
response.body.should == "A is for Archer, an excellent typeface."
end
end
describe "post_file" do
@@ -179,11 +179,11 @@
end
it 'should return a CurbFu::Response object' do
response = CurbFu::Request.post_file('http://a.example.com/gimme/html')
response.should be_a_kind_of(CurbFu::Response::Base)
response.status.should == 200
- response.headers.should == { 'Content-Type' => 'spec/testcase' }
+ response.headers.should == { 'Content-Type' => 'spec/testcase', "Content-Length"=>"39" }
response.body.should == "A is for Archer, an excellent typeface."
end
end
describe "put" do
@@ -196,11 +196,11 @@
end
it 'should return a CurbFu::Response object' do
response = CurbFu::Request.put('http://a.example.com/gimme/html')
response.should be_a_kind_of(CurbFu::Response::Base)
response.status.should == 200
- response.headers.should == { 'Content-Type' => 'spec/testcase' }
+ response.headers.should == { 'Content-Type' => 'spec/testcase', "Content-Length"=>"39" }
response.body.should == "A is for Archer, an excellent typeface."
end
end
describe "delete" do
@@ -214,10 +214,10 @@
end
it 'should return a CurbFu::Response object' do
response = CurbFu::Request.delete('http://a.example.com/gimme/html')
response.should be_a_kind_of(CurbFu::Response::Base)
response.status.should == 200
- response.headers.should == { 'Content-Type' => 'spec/testcase' }
+ response.headers.should == { 'Content-Type' => 'spec/testcase', "Content-Length"=>"39" }
response.body.should == "A is for Archer, an excellent typeface."
end
end
end