diff options
Diffstat (limited to 't/fast-pipe-response.ru')
-rw-r--r-- | t/fast-pipe-response.ru | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/t/fast-pipe-response.ru b/t/fast-pipe-response.ru new file mode 100644 index 0000000..01f4d59 --- /dev/null +++ b/t/fast-pipe-response.ru @@ -0,0 +1,12 @@ +# must be run without Rack::Lint since that clobbers to_path +use Rainbows::DevFdResponse +run(lambda { |env| + env['rainbows.autochunk'] = false + [ 200, + { + 'X-Rainbows-Autochunk' => 'no', + 'Content-Length' => ::File.stat('random_blob').size.to_s, + 'Content-Type' => 'application/octet-stream', + }, + IO.popen('cat random_blob', 'rb') ] +}) |