aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAaron Patterson <aaron.patterson@gmail.com>2012-01-06 10:51:39 -0800
committerAaron Patterson <aaron.patterson@gmail.com>2012-01-06 10:51:39 -0800
commit3abacc0a700835afbbda53e153bb9105bcc68738 (patch)
tree9850cf6398d42879e07646d6dc5c356dcaa3c151
parentc8fef32a661311b31bbeb207bb799af61a8f750b (diff)
parent2fc3a30e1775732cfa0f84256b452197465f4c7f (diff)
downloadrails-3abacc0a700835afbbda53e153bb9105bcc68738.tar.gz
rails-3abacc0a700835afbbda53e153bb9105bcc68738.tar.bz2
rails-3abacc0a700835afbbda53e153bb9105bcc68738.zip
Merge pull request #4357 from rafaelfranca/patch-1
Remove more references to Test::Unit
-rw-r--r--activesupport/lib/active_support/testing/deprecation.rb19
-rw-r--r--activesupport/test/deprecation_test.rb2
2 files changed, 1 insertions, 20 deletions
diff --git a/activesupport/lib/active_support/testing/deprecation.rb b/activesupport/lib/active_support/testing/deprecation.rb
index 0135185a47..a8342904dc 100644
--- a/activesupport/lib/active_support/testing/deprecation.rb
+++ b/activesupport/lib/active_support/testing/deprecation.rb
@@ -34,22 +34,3 @@ module ActiveSupport
end
end
end
-
-begin
- require 'test/unit/error'
-rescue LoadError
- # Using miniunit, ignore.
-else
- module Test
- module Unit
- class Error #:nodoc:
- # Silence warnings when reporting test errors.
- def message_with_silenced_deprecation
- ActiveSupport::Deprecation.silence { message_without_silenced_deprecation }
- end
- alias_method :message_without_silenced_deprecation, :message
- alias_method :message, :message_with_silenced_deprecation
- end
- end
- end
-end
diff --git a/activesupport/test/deprecation_test.rb b/activesupport/test/deprecation_test.rb
index 4daffb85d2..e821a285d7 100644
--- a/activesupport/test/deprecation_test.rb
+++ b/activesupport/test/deprecation_test.rb
@@ -120,7 +120,7 @@ class DeprecationTest < ActiveSupport::TestCase
ActiveSupport::Deprecation.warn 'abc'
ActiveSupport::Deprecation.warn 'def'
end
- rescue Test::Unit::AssertionFailedError
+ rescue MiniTest::Assertion
flunk 'assert_deprecated should match any warning in block, not just the last one'
end