rack.git  about / heads / tags
a modular Ruby webserver interface
blob b3c2bc9c6584286366977a98f9f1cfac61ecdd42 315 bytes (raw)
$ git show rack.io:test/spec_rack_nulllogger.rb	# shows this blob on the CLI

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
 
require 'rack/nulllogger'
require 'rack/lint'
require 'rack/mock'

context "Rack::NullLogger" do
  specify "acks as a nop logger" do
    app = lambda { |env|
      env['rack.logger'].warn "b00m"
      [200, {'Content-Type' => 'text/plain'}, ["Hello, World!"]]
    }
    Rack::NullLogger.new(app).call({})
  end
end

git clone https://yhbt.net/rack.git