diff options
Diffstat (limited to 'spec/ruby/library/net/http/httpheader/shared/size.rb')
-rw-r--r-- | spec/ruby/library/net/http/httpheader/shared/size.rb | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/spec/ruby/library/net/http/httpheader/shared/size.rb b/spec/ruby/library/net/http/httpheader/shared/size.rb new file mode 100644 index 0000000000..e2b1e4c22b --- /dev/null +++ b/spec/ruby/library/net/http/httpheader/shared/size.rb @@ -0,0 +1,18 @@ +describe :net_httpheader_size, shared: true do + before :each do + @headers = NetHTTPHeaderSpecs::Example.new + end + + it "returns the number of header entries in self" do + @headers.send(@method).should eql(0) + + @headers["a"] = "b" + @headers.send(@method).should eql(1) + + @headers["b"] = "b" + @headers.send(@method).should eql(2) + + @headers["c"] = "c" + @headers.send(@method).should eql(3) + end +end |