aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test/deprecation_test.rb
diff options
context:
space:
mode:
authorMatthew Draper <matthew@trebex.net>2015-10-17 03:08:58 +1030
committerMatthew Draper <matthew@trebex.net>2015-10-17 03:17:21 +1030
commit833aef438dab57c2c6523686fa9754faa023cd10 (patch)
treed399ae7ffb2276726b37131fe3059964f6fcebce /activesupport/test/deprecation_test.rb
parentcd4575f98c11bfa698c0c7b6a3e1feae64006a76 (diff)
parent6c98fbd9c3cc28ccbfc1b46a9ce3d58fdb19f3c8 (diff)
downloadrails-833aef438dab57c2c6523686fa9754faa023cd10.tar.gz
rails-833aef438dab57c2c6523686fa9754faa023cd10.tar.bz2
rails-833aef438dab57c2c6523686fa9754faa023cd10.zip
Merge pull request #21953 from bdunne/fix_dep_warn
Fix deprecation warning messages on deprecate_methods
Diffstat (limited to 'activesupport/test/deprecation_test.rb')
-rw-r--r--activesupport/test/deprecation_test.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/activesupport/test/deprecation_test.rb b/activesupport/test/deprecation_test.rb
index 7e8844b301..cd02ad3f3f 100644
--- a/activesupport/test/deprecation_test.rb
+++ b/activesupport/test/deprecation_test.rb
@@ -163,6 +163,14 @@ class DeprecationTest < ActiveSupport::TestCase
assert_not_deprecated { assert_equal Deprecatee::B::C.class, Deprecatee::A.class }
end
+ def test_assert_deprecated_raises_when_method_not_deprecated
+ assert_raises(Minitest::Assertion) { assert_deprecated { @dtc.not } }
+ end
+
+ def test_assert_not_deprecated
+ assert_raises(Minitest::Assertion) { assert_not_deprecated { @dtc.partially } }
+ end
+
def test_assert_deprecation_without_match
assert_deprecated do
@dtc.partially