Skip to content

Commit

Permalink
Fix test of line number in HEREDOC in Ruby 3.3
Browse files Browse the repository at this point in the history
  • Loading branch information
judofyr committed Feb 10, 2024
1 parent c5bcf76 commit f287412
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions language/heredoc_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@

it "reports line numbers inside HEREDOC with method call" do
-> {
eval %{<<HERE.chomp\na\nb\#{c}\nHERE}
}.should raise_error(NameError) { |e| e.backtrace[0].should.start_with?("(eval):3") }
eval %{<<HERE.chomp\na\nb\#{c}\nHERE}, nil, "example"
}.should raise_error(NameError) { |e| e.backtrace[0].should.start_with?("example:3") }
end
end

0 comments on commit f287412

Please sign in to comment.