Method: ActiveSupport::LogSubscriber::TestHelper#setup

Defined in:
activesupport/lib/active_support/log_subscriber/test_helper.rb

#setupObject

:nodoc:



38
39
40
41
42
43
44
45
46
47
# File 'activesupport/lib/active_support/log_subscriber/test_helper.rb', line 38

def setup # :nodoc:
  @logger   = MockLogger.new
  @notifier = ActiveSupport::Notifications::Fanout.new

  ActiveSupport::LogSubscriber.colorize_logging = false

  @old_notifier = ActiveSupport::Notifications.notifier
  set_logger(@logger)
  ActiveSupport::Notifications.notifier = @notifier
end