summaryrefslogtreecommitdiff
path: root/spec/ruby/core/struct/hash_spec.rb
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2020-02-08 19:43:27 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2020-04-01 15:36:20 +0900
commit826f44834fe11f3f9c52343443a15b6c83466889 (patch)
treef2c2abed62db1c750515cd8b0fbac6442b6d4200 /spec/ruby/core/struct/hash_spec.rb
parent3a2073e61b6ccce6d07d31ebd89d4c385b9a55f2 (diff)
Drop support for ruby 2.4 from ruby/spec
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/2892
Diffstat (limited to 'spec/ruby/core/struct/hash_spec.rb')
-rw-r--r--spec/ruby/core/struct/hash_spec.rb14
1 files changed, 6 insertions, 8 deletions
diff --git a/spec/ruby/core/struct/hash_spec.rb b/spec/ruby/core/struct/hash_spec.rb
index 5ed4ace489..545929e402 100644
--- a/spec/ruby/core/struct/hash_spec.rb
+++ b/spec/ruby/core/struct/hash_spec.rb
@@ -25,14 +25,12 @@ describe "Struct#hash" do
s1.hash.should_not == s2.hash
end
- ruby_version_is "2.5" do
- it "returns different hashes for structs with different values when using keyword_init: true" do
- key = :"1 non symbol member"
- struct_class = Struct.new(key, keyword_init: true)
- t1 = struct_class.new(key => 1)
- t2 = struct_class.new(key => 2)
- t1.hash.should_not == t2.hash
- end
+ it "returns different hashes for structs with different values when using keyword_init: true" do
+ key = :"1 non symbol member"
+ struct_class = Struct.new(key, keyword_init: true)
+ t1 = struct_class.new(key => 1)
+ t2 = struct_class.new(key => 2)
+ t1.hash.should_not == t2.hash
end
it "allows for overriding methods in an included module" do