spec/response_spec.rb in patron-0.4.15 vs spec/response_spec.rb in patron-0.4.16

- old
+ new

@@ -40,6 +40,13 @@ it "should return an array of values when multiple header fields have same name" do response = @session.get("/repetitiveheader") response.headers['Set-Cookie'].should == ["a=1","b=2"] end + + it "should not allow a default charset to be nil" do + Encoding.stub(:default_internal).and_return("UTF-8") + expect { + Patron::Response.new("url", "status", 0, "", "", nil) + }.to_not raise_error + end end