Sha256: 631655f22c9b3ada42c2ef4c10b4cdf48ab3728e5a199eb869a1b3666ff6fa68
Contents?: true
Size: 660 Bytes
Versions: 2
Compression:
Stored size: 660 Bytes
Contents
require 'spec_helper' describe Riak::Util::Headers do it "should include the Net::HTTPHeader module" do Riak::Util::Headers.included_modules.should include(Net::HTTPHeader) end it "should be initially empty" do Riak::Util::Headers.new.to_hash.should == {} end it "should parse a header line into the key and value" do Riak::Util::Headers.parse("Content-Type: text/plain\r\n").should == ["Content-Type", "text/plain"] end it "should parse a header line and add it to the collection" do h = Riak::Util::Headers.new h.parse("Content-Type: text/plain\r\n") h.to_hash.should == {"content-type" => ["text/plain"]} end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
riak-client-1.4.5 | spec/riak/headers_spec.rb |
riak-client-1.4.4.1 | spec/riak/headers_spec.rb |