summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-12-11 10:17:13 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-12-11 10:17:13 +0000
commit4db3a06d6f18d69879340510b25ddd704a00dff0 (patch)
treee21b3ed74b6bb363af10434837ae29bdf79348e0 /test
parent4a2867abe169c563e463f749923a7dbed640c409 (diff)
merge revision(s) 38235: [Backport #7255]
* parse.y (parser_here_document): flush string content between new line and :string_embexpr. [ruby-core:48703] [Bug #7255] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_9_3@38319 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r--test/ripper/test_scanner_events.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/ripper/test_scanner_events.rb b/test/ripper/test_scanner_events.rb
index e792ca8f4d..c92ec494ed 100644
--- a/test/ripper/test_scanner_events.rb
+++ b/test/ripper/test_scanner_events.rb
@@ -657,6 +657,13 @@ class TestRipper::ScannerEvents < Test::Unit::TestCase
scan('tstring_content', "<<EOS\nhere\ndoc \nEOS \n")
assert_equal ["heredoc\n\tEOS \n"],
scan('tstring_content', "<<-EOS\nheredoc\n\tEOS \n")
+ bug7255 = '[ruby-core:48703]'
+ assert_equal ["there\n""heredoc", "\n"],
+ scan('tstring_content', "<<""EOS\n""there\n""heredoc\#{foo}\nEOS"),
+ bug7255
+ assert_equal ["there\n""heredoc", "\n"],
+ scan('tstring_content', "<<""EOS\n""there\n""heredoc\#@foo\nEOS"),
+ bug7255
end
def test_heredoc_end