ruby-changes:41496
From: nobu <ko1@a...>
Date: Mon, 18 Jan 2016 01:14:09 +0900 (JST)
Subject: [ruby-changes:41496] nobu:r53570 (trunk): test_syntax.rb: try all
nobu 2016-01-18 01:14:44 +0900 (Mon, 18 Jan 2016) New Revision: 53570 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=53570 Log: test_syntax.rb: try all * test/ruby/test_syntax.rb (assert_dedented_heredoc): try all terminators regardless failures. Modified files: trunk/test/ruby/test_syntax.rb Index: test/ruby/test_syntax.rb =================================================================== --- test/ruby/test_syntax.rb (revision 53569) +++ test/ruby/test_syntax.rb (revision 53570) @@ -501,10 +501,13 @@ e" https://github.com/ruby/ruby/blob/trunk/test/ruby/test_syntax.rb#L501 end def assert_dedented_heredoc(expect, result, mesg = "") - %w[eos "eos" 'eos' `eos`].each do |eos| - assert_equal(eval("<<-#{eos}\n#{expect}eos\n"), - eval("<<~#{eos}\n#{result}eos\n"), - message(mesg) {"with #{eos}"}) + all_assertions(mesg) do |a| + %w[eos "eos" 'eos' `eos`].each do |eos| + a.for(eos) do + assert_equal(eval("<<-#{eos}\n#{expect}eos\n"), + eval("<<~#{eos}\n#{result}eos\n")) + end + end end end -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/