From a5bfe7ca837c81e2df0329d4004fabfb4178362e Mon Sep 17 00:00:00 2001 From: nobu Date: Fri, 13 Jan 2012 07:44:50 +0000 Subject: * error.c (exc_equal): try implicit conversion for delegator. [ruby-core:41979] [Bug #5865] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34291 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/ruby/test_exception.rb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'test/ruby') diff --git a/test/ruby/test_exception.rb b/test/ruby/test_exception.rb index 028391d1e6..22ac2aca1f 100644 --- a/test/ruby/test_exception.rb +++ b/test/ruby/test_exception.rb @@ -380,4 +380,10 @@ end.join load(t.path) end end + + def test_equal + bug5865 = '[ruby-core:41979]' + assert_equal(RuntimeError.new("a"), RuntimeError.new("a"), bug5865) + assert_not_equal(RuntimeError.new("a"), StandardError.new("a"), bug5865) + end end -- cgit v1.2.3