diff options
Diffstat (limited to 'railties/test')
-rw-r--r-- | railties/test/log_subscriber_test.rb | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/railties/test/log_subscriber_test.rb b/railties/test/log_subscriber_test.rb index be176df1bb..a4de023e65 100644 --- a/railties/test/log_subscriber_test.rb +++ b/railties/test/log_subscriber_test.rb @@ -79,7 +79,7 @@ class SyncLogSubscriberTest < ActiveSupport::TestCase Rails::LogSubscriber.add :my_log_subscriber, @log_subscriber instrument "my_log_subscriber.unknown_event" wait - # If we get here, it means that NoMethodError was raised. + # If we get here, it means that NoMethodError was not raised. end def test_does_not_send_the_event_if_logger_is_nil @@ -90,6 +90,12 @@ class SyncLogSubscriberTest < ActiveSupport::TestCase wait end + def test_does_not_fail_with_non_namespaced_events + Rails::LogSubscriber.add :my_log_subscriber, @log_subscriber + instrument "whatever" + wait + end + def test_flushes_loggers Rails::LogSubscriber.add :my_log_subscriber, @log_subscriber Rails::LogSubscriber.flush_all! |