summary refs log tree commit homepage
path: root/t/t0016.rb
blob: 98c9a2e3540420a2cda8e36d20be82a0706c30c6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# -*- encoding: utf-8 -*-
module T0016
  CHUNK = '©' * 1024 * 1024
  BODY = (1..50).map { CHUNK }
  HEADER = {
    # BODY.inject(0) { |m,c| m += c.bytesize }.to_s,
    'Content-Length' => '104857600',
    'Content-Type' => 'text/plain',
  }

  def self.call(env)
    [ 200, HEADER, BODY ]
  end
end
$0 == __FILE__ and T0016::BODY.each { |x| $stdout.syswrite(x) }