summaryrefslogtreecommitdiff
path: root/spec/ruby/language/pattern_matching_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/ruby/language/pattern_matching_spec.rb')
-rw-r--r--spec/ruby/language/pattern_matching_spec.rb12
1 files changed, 7 insertions, 5 deletions
diff --git a/spec/ruby/language/pattern_matching_spec.rb b/spec/ruby/language/pattern_matching_spec.rb
index 91ad23bf32..2d22ec7e64 100644
--- a/spec/ruby/language/pattern_matching_spec.rb
+++ b/spec/ruby/language/pattern_matching_spec.rb
@@ -9,11 +9,13 @@ ruby_version_is "2.7" do
ScratchPad.record []
end
- it "can be standalone in operator that deconstructs value" do
- eval(<<-RUBY).should == [0, 1]
- [0, 1] in [a, b]
- [a, b]
- RUBY
+ ruby_version_is "3.0" do
+ it "can be standalone assoc operator that deconstructs value" do
+ eval(<<-RUBY).should == [0, 1]
+ [0, 1] => [a, b]
+ [a, b]
+ RUBY
+ end
end
it "extends case expression with case/in construction" do