[Bug #20978] Use ruby_bug instead of ruby_version_is

This commit is contained in:
Nobuyoshi Nakada 2024-12-23 19:21:46 +09:00
parent adad97a031
commit bf5f8ecef1
No known key found for this signature in database
GPG Key ID: 3582D74E1FEE4465
Notes: git 2024-12-23 11:13:09 +00:00

View File

@ -92,16 +92,7 @@ ruby_version_is "3.2" do
end end
end end
ruby_version_is "3.2.3"..."3.4" do ruby_bug "#20978", "3.2.3"..."3.4" do
it "can't use invalid keys" do
invalid_keys = [Object.new, "Foo", 12]
invalid_keys.each do |key|
-> { Fiber[key] }.should raise_error(TypeError)
end
end
end
ruby_version_is "3.4" do
it "can use keys as strings" do it "can use keys as strings" do
key = Object.new key = Object.new
def key.to_str; "Foo"; end def key.to_str; "Foo"; end