1
0
Fork 0
mirror of https://github.com/thoughtbot/capybara-webkit synced 2023-03-27 23:22:28 -04:00

Make stdout deprecation warning more specific

In a Rails application with a large number of dependencies, it's hard to
know which library is emitting a warning. This adds "capybara-webkit" to
the deprecation warning.

Resolves #607.
This commit is contained in:
Mike Perham 2014-01-09 18:00:47 -05:00 committed by Joe Ferris
parent 681aa64bf2
commit 40a5b251d2

View file

@ -16,7 +16,8 @@ module Capybara::Webkit
if options.has_key?(:stderr) if options.has_key?(:stderr)
@output_target = options[:stderr] @output_target = options[:stderr]
elsif options.has_key?(:stdout) elsif options.has_key?(:stdout)
warn "[DEPRECATION] The `stdout` option is deprecated. Please use `stderr` instead." warn '[DEPRECATION] The Capybara::Webkit::Connection `stdout` option ' \
'is deprecated. Please use `stderr` instead.'
@output_target = options[:stdout] @output_target = options[:stdout]
else else
@output_target = $stderr @output_target = $stderr