summaryrefslogtreecommitdiff
path: root/test/digest/test_digest.rb
diff options
context:
space:
mode:
authoreregon <eregon@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-06-06 21:05:48 +0000
committereregon <eregon@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-06-06 21:05:48 +0000
commitbc211f363443062b3218dd065218f93af10e44ff (patch)
tree3b124f9a33cd2bdf91f4601cc538b481d7a62696 /test/digest/test_digest.rb
parentfd8b2547054fffe8dd01631b50e917df47c5b637 (diff)
digest.c: fix #== for non-string arguments
* ext/digest/digest.c (rb_digest_instance_equal): fix #== for non-string arguments. [ruby-core:62967] [Bug #9913] * test/digest/test_digest.rb: add test for above. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46368 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/digest/test_digest.rb')
-rwxr-xr-xtest/digest/test_digest.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/digest/test_digest.rb b/test/digest/test_digest.rb
index 86f9147..cf541a4 100755
--- a/test/digest/test_digest.rb
+++ b/test/digest/test_digest.rb
@@ -69,6 +69,9 @@ module TestDigest
assert_equal(md1, md1.clone, self.class::ALGO)
+ bug9913 = '[ruby-core:62967] [Bug #9913]'
+ assert_not_equal(md1, nil, bug9913)
+
md2 = self.class::ALGO.new
md2 << "A"