diff --git a/test/protocol/rack/body/streaming.rb b/test/protocol/rack/body/streaming.rb index 267344e..8b81071 100644 --- a/test/protocol/rack/body/streaming.rb +++ b/test/protocol/rack/body/streaming.rb @@ -38,4 +38,18 @@ expect(stream.string).to be == "HelloWorld" end end + + with "nested fiber" do + let(:block) do + proc do |stream| + Fiber.new do + stream.write("Hello") + end.resume + end + end + + it "can read a chunk" do + expect(body.read).to be == "Hello" + end + end end