diff options
author | Samuel Williams <samuel.williams@oriontransfer.co.nz> | 2020-01-07 22:53:12 +1300 |
---|---|---|
committer | Samuel Williams <samuel.williams@oriontransfer.co.nz> | 2020-01-07 22:53:12 +1300 |
commit | 844fa194b71d711e45d2968611d7a47c50f493c4 (patch) | |
tree | 5bb9c19e1b0584d9cc34e56655d1f7f307b2d09b | |
parent | 15ea47da9782379a1ad2d2285920f9b1a08feacf (diff) | |
download | rack-response-buffered.tar.gz |
Restore part of status=205 spec.rack-response-buffered
-rw-r--r-- | test/spec_response.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/spec_response.rb b/test/spec_response.rb index 5f9a5afc..c0736c73 100644 --- a/test/spec_response.rb +++ b/test/spec_response.rb @@ -480,6 +480,15 @@ describe Rack::Response do b.wont_equal res.body end + it "doesn't call close on #body when 205" do + res = Rack::Response.new + + res.body = StringIO.new + res.status = 205 + _, _, b = res.finish + res.body.wont_be :closed? + end + it "flatten doesn't cause infinite loop" do # https://github.com/rack/rack/issues/419 res = Rack::Response.new("Hello World") |