From 144006a20e7d97733d682ff1502f24b032b3db59 Mon Sep 17 00:00:00 2001 From: "Yukihiro \"Matz\" Matsumoto" Date: Sat, 3 Dec 2016 18:23:04 +0900 Subject: update NoMethodError tests; ref #3291 --- test/t/nomethoderror.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/t/nomethoderror.rb b/test/t/nomethoderror.rb index ce3514782..1c09bc20e 100644 --- a/test/t/nomethoderror.rb +++ b/test/t/nomethoderror.rb @@ -22,7 +22,7 @@ assert('NoMethodError#args', '15.2.32.2.1') do end assert('Can still raise when BasicObject#method_missing is removed') do - assert_raise(TypeError) do + assert_raise(NoMethodError) do begin BasicObject.alias_method(:old_method_missing, :method_missing) BasicObject.remove_method(:method_missing) @@ -35,7 +35,7 @@ assert('Can still raise when BasicObject#method_missing is removed') do end assert('Can still call super when BasicObject#method_missing is removed') do - assert_raise(TypeError) do + assert_raise(NoMethodError) do class A def foo super -- cgit v1.2.3