summaryrefslogtreecommitdiff
path: root/test/minitest
diff options
context:
space:
mode:
authormame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-12-26 09:04:12 +0000
committermame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-12-26 09:04:12 +0000
commite030e9f0b8be42dd8c5eb43e3f390106f3b6a48e (patch)
tree5626921dc90c6d24dcd809c54ae2e714931217dc /test/minitest
parent2b21744efa34a685d0b3d3b333622989a7615cda (diff)
downloadruby-e030e9f0b8be42dd8c5eb43e3f390106f3b6a48e.tar.gz
object.c (rb_obj_match): use rb_warn for deprecation warning
Now the warning is printed even without -w option. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66576 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/minitest')
-rw-r--r--test/minitest/test_minitest_unit.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/test/minitest/test_minitest_unit.rb b/test/minitest/test_minitest_unit.rb
index 3d92b865c3..f59bc45c26 100644
--- a/test/minitest/test_minitest_unit.rb
+++ b/test/minitest/test_minitest_unit.rb
@@ -1529,7 +1529,9 @@ class TestMiniTestUnitTestCase < MiniTest::Unit::TestCase
def test_refute_match_matcher_object
@assertion_count = 2
non_verbose do
- @tc.refute_match Object.new, 5 # default #=~ returns false
+ obj = Object.new
+ def obj.=~(other); false; end
+ @tc.refute_match obj, 5
end
end