File tree Expand file tree Collapse file tree 2 files changed +16
-4
lines changed
Expand file tree Collapse file tree 2 files changed +16
-4
lines changed Original file line number Diff line number Diff line change 9898 end
9999 end
100100
101- with "backward compatibility" do
102- it "can initialize with string" do
101+ with ".new" do
102+ it "preserves values when given array" do
103+ header = subject . new ( [ "text/html" , "application/json" ] )
104+ expect ( header ) . to be ( :include? , "text/html" )
105+ expect ( header ) . to be ( :include? , "application/json" )
106+ end
107+
108+ it "can initialize with string (backward compatibility)" do
103109 header = subject . new ( "text/plain, text/html" )
104110 expect ( header ) . to be ( :include? , "text/plain" )
105111 expect ( header ) . to be ( :include? , "text/html" )
Original file line number Diff line number Diff line change 7474 end
7575 end
7676
77- with "backward compatibility" do
78- it "can initialize with string for backward compatibility" do
77+ with ".new" do
78+ it "preserves values when given array" do
79+ header = subject . new ( [ "etag" , "content-md5" ] )
80+ expect ( header ) . to be ( :include? , "etag" )
81+ expect ( header ) . to be ( :include? , "content-md5" )
82+ end
83+
84+ it "can initialize with string (backward compatibility)" do
7985 header = subject . new ( "etag, content-md5" )
8086 expect ( header ) . to be ( :include? , "etag" )
8187 expect ( header ) . to be ( :include? , "content-md5" )
You can’t perform that action at this time.
0 commit comments