From 40651cf1f567ae728c8d2cc908017c31e1000b6e Mon Sep 17 00:00:00 2001 From: Koichi Sasada Date: Wed, 31 Jul 2019 15:12:57 +0900 Subject: delete a check on bad assumption. If object was modified, but there is a case that hash values (#hash) are same between before modified and after modified objects. --- spec/ruby/core/hash/rehash_spec.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'spec/ruby/core') diff --git a/spec/ruby/core/hash/rehash_spec.rb b/spec/ruby/core/hash/rehash_spec.rb index 9816648f08..2af287cd70 100644 --- a/spec/ruby/core/hash/rehash_spec.rb +++ b/spec/ruby/core/hash/rehash_spec.rb @@ -10,7 +10,11 @@ describe "Hash#rehash" do h[k2] = 1 k1 << 2 - h.key?(k1).should == false + + # if k1 is modified to k1', k1.hash and k1'.hash can be same. + # So this test has an issue. For the present, this line is commented out. + # h.key?(k1).should == false + h.keys.include?(k1).should == true h.rehash.should equal(h) -- cgit v1.2.3