Permalink
Browse files

Make webrick logging visible on CI but not locally.

  • Loading branch information...
1 parent f52b13a commit 7be1de958f5f368908c784dac7e3405585c4ff1b @myronmarston committed May 14, 2011
Showing with 5 additions and 1 deletion.
  1. +2 −0 .travis.yml
  2. +3 −1 spec/support/vcr_localhost_server.rb
View
@@ -1,3 +1,5 @@
script: "bundle exec cucumber --profile wip"
rvm:
- 1.9.2
+env:
+ - CI=true
@@ -40,7 +40,9 @@ def find_available_port
def boot
# Use WEBrick since it's part of the ruby standard library and is available on all ruby interpreters.
- Rack::Handler::WEBrick.run(Identify.new(@rack_app), :Port => port)
+ options = { :Port => port }
+ options.merge!(:AccessLog => [], :Logger => WEBrick::BasicLog.new(StringIO.new)) unless ENV['CI']
+ Rack::Handler::WEBrick.run(Identify.new(@rack_app), options)
end
def booted?

0 comments on commit 7be1de9

Please sign in to comment.