about summary refs log tree commit homepage
path: root/t/t0301.ru
blob: 1ae8ea7b405ebe3f4dce950a40b23dccb5db7144 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#\-N --debug
run(lambda do |env|
  case env['PATH_INFO']
  when '/vars'
    b = "debug=#{$DEBUG.inspect}\n" \
        "lint=#{caller.grep(%r{rack/lint\.rb})[0].split(':')[0]}\n"
  end
  h = {
    'Content-Length' => b.size.to_s,
    'Content-Type' => 'text/plain',
  }
  [ 200, h, [ b ] ]
end)