Skip to content

Commit 0fd909e

Browse files
Add check for optional body.
1 parent e3427c3 commit 0fd909e

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

test/protocol/rack/adapter/rack31.rb

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,15 @@
6060
end
6161
end
6262
end
63+
64+
with "a non-empty body" do
65+
let(:body) {Protocol::HTTP::Body::Buffered.wrap("Hello World!")}
66+
67+
it "should return an empty body" do
68+
env = adapter.make_environment(request)
69+
expect(env).to have_keys(Protocol::Rack::RACK_INPUT)
70+
end
71+
end
6372

6473
with "a request that has response finished callbacks" do
6574
let(:callback) {->(env, status, headers, error){}}

0 commit comments

Comments
 (0)