diff options
author | José Valim <jose.valim@gmail.com> | 2010-02-07 13:44:47 +0100 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2010-02-07 13:45:47 +0100 |
commit | 345e0b274cb384f8d453256e90dd105e6c2ffa19 (patch) | |
tree | 257bb4a798dffe86f2da5bac825cf71202041cbc /railties/lib/rails | |
parent | de69c798db5535f19bfd585da83117fe1dacd6d9 (diff) | |
download | rails-345e0b274cb384f8d453256e90dd105e6c2ffa19.tar.gz rails-345e0b274cb384f8d453256e90dd105e6c2ffa19.tar.bz2 rails-345e0b274cb384f8d453256e90dd105e6c2ffa19.zip |
Add backtrace cleaner on test unit railtie.
Diffstat (limited to 'railties/lib/rails')
-rw-r--r-- | railties/lib/rails/test_unit/railtie.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/railties/lib/rails/test_unit/railtie.rb b/railties/lib/rails/test_unit/railtie.rb index 21b9dbc074..f7f07ac053 100644 --- a/railties/lib/rails/test_unit/railtie.rb +++ b/railties/lib/rails/test_unit/railtie.rb @@ -13,5 +13,13 @@ module Rails rake_tasks do load "rails/test_unit/testing.rake" end + + initializer "test_unit.backtrace_cleaner" do + # TODO: Figure out how to get the Rails::BacktraceFilter into minitest/unit + unless defined?(Minitest) || ENV['BACKTRACE'] + require 'rails/backtrace_cleaner' + Test::Unit::Util::BacktraceFilter.module_eval { include Rails::BacktraceFilterForTestUnit } + end + end end end
\ No newline at end of file |