diff options
-rw-r--r-- | activesupport/lib/active_support/backtrace_cleaner.rb | 1 | ||||
-rw-r--r-- | railties/lib/rails/test_help.rb | 4 |
2 files changed, 5 insertions, 0 deletions
diff --git a/activesupport/lib/active_support/backtrace_cleaner.rb b/activesupport/lib/active_support/backtrace_cleaner.rb index 53d05c3817..47898f8047 100644 --- a/activesupport/lib/active_support/backtrace_cleaner.rb +++ b/activesupport/lib/active_support/backtrace_cleaner.rb @@ -45,6 +45,7 @@ module ActiveSupport filtered end end + alias :filter :clean # Adds a filter from the block provided. Each line in the backtrace will be # mapped against this filter. diff --git a/railties/lib/rails/test_help.rb b/railties/lib/rails/test_help.rb index 581ceaf9ce..aa357dc418 100644 --- a/railties/lib/rails/test_help.rb +++ b/railties/lib/rails/test_help.rb @@ -7,6 +7,10 @@ require 'active_support/test_case' require 'action_controller/test_case' require 'action_dispatch/testing/integration' +# Config Rails backtrace in tests. +require 'rails/backtrace_cleaner' +MiniTest.backtrace_filter = Rails.backtrace_cleaner + # Enable turn if it is available begin require 'turn' |