mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Update to ruby/spec@3affe1e
This commit is contained in:
parent
6ae81d49b5
commit
45cf4f2187
277 changed files with 3844 additions and 7624 deletions
|
@ -59,20 +59,10 @@ HERE
|
|||
s.encoding.should == Encoding::US_ASCII
|
||||
end
|
||||
|
||||
ruby_version_is "2.7" do
|
||||
it 'raises SyntaxError if quoted HEREDOC identifier is ending not on same line' do
|
||||
-> {
|
||||
eval %{<<"HERE\n"\nraises syntax error\nHERE}
|
||||
}.should raise_error(SyntaxError)
|
||||
end
|
||||
end
|
||||
|
||||
ruby_version_is ""..."2.7" do
|
||||
it 'prints a warning if quoted HEREDOC identifier is ending not on same line' do
|
||||
-> {
|
||||
eval %{<<"HERE\n"\nit warns\nHERE}
|
||||
}.should complain(/here document identifier ends with a newline/)
|
||||
end
|
||||
it 'raises SyntaxError if quoted HEREDOC identifier is ending not on same line' do
|
||||
-> {
|
||||
eval %{<<"HERE\n"\nraises syntax error\nHERE}
|
||||
}.should raise_error(SyntaxError)
|
||||
end
|
||||
|
||||
it "allows HEREDOC with <<~'identifier', allowing to indent identifier and content" do
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue