Skip to content

Commit

Permalink
Update to latest Prism syntax error messages
Browse files Browse the repository at this point in the history
  • Loading branch information
eregon committed Jan 30, 2024
1 parent 2f16599 commit 9b405d7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions spec/ruby/language/pattern_matching_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@
in []
end
RUBY
}.should raise_error(SyntaxError, /syntax error, unexpected `in'|\(eval\):3: syntax error, unexpected keyword_in|cannot parse the expression/)
}.should raise_error(SyntaxError, /syntax error, unexpected `in'|\(eval\):3: syntax error, unexpected keyword_in|unexpected 'in'/)

-> {
eval <<~RUBY
Expand All @@ -216,7 +216,7 @@
when 1 == 1
end
RUBY
}.should raise_error(SyntaxError, /syntax error, unexpected `when'|\(eval\):3: syntax error, unexpected keyword_when|cannot parse the expression/)
}.should raise_error(SyntaxError, /syntax error, unexpected `when'|\(eval\):3: syntax error, unexpected keyword_when|unexpected 'when'/)
end

it "checks patterns until the first matching" do
Expand Down

0 comments on commit 9b405d7

Please sign in to comment.