ruby-changes:62637
From: Yusuke <ko1@a...>
Date: Tue, 18 Aug 2020 23:33:55 +0900 (JST)
Subject: [ruby-changes:62637] bed6b7206a (master): test/irb/test_history.rb: prevent warnings
https://git.ruby-lang.org/ruby.git/commit/?id=bed6b7206a From bed6b7206a64eeca5b521e02799da4055d9f5e55 Mon Sep 17 00:00:00 2001 From: Yusuke Endoh <mame@r...> Date: Tue, 18 Aug 2020 23:32:46 +0900 Subject: test/irb/test_history.rb: prevent warnings ``` /home/chkbuild/chkbuild/tmp/build/20200818T123003Z/ruby/test/irb/test_history.rb:16: warning: assigned but unused variable - result_output /home/chkbuild/chkbuild/tmp/build/20200818T123003Z/ruby/test/irb/test_history.rb:34: warning: assigned but unused variable - result_output /home/chkbuild/chkbuild/tmp/build/20200818T123003Z/ruby/test/irb/test_history.rb:57: warning: assigned but unused variable - result_output /home/chkbuild/chkbuild/tmp/build/20200818T123003Z/ruby/test/irb/test_history.rb:80: warning: assigned but unused variable - result_output ``` diff --git a/test/irb/test_history.rb b/test/irb/test_history.rb index 430661c..0b3620f 100644 --- a/test/irb/test_history.rb +++ b/test/irb/test_history.rb @@ -13,7 +13,7 @@ module TestIRB https://github.com/ruby/ruby/blob/trunk/test/irb/test_history.rb#L13 end def test_history_save_1 - result_output, result_history_file = launch_irb_with_irbrc_and_irb_history(<<~IRBRC, <<~IRB_HISTORY) do |stdin| + _result_output, result_history_file = launch_irb_with_irbrc_and_irb_history(<<~IRBRC, <<~IRB_HISTORY) do |stdin| IRB.conf[:USE_READLINE] = true IRB.conf[:SAVE_HISTORY] = 1 IRBRC @@ -31,7 +31,7 @@ module TestIRB https://github.com/ruby/ruby/blob/trunk/test/irb/test_history.rb#L31 end def test_history_save_100 - result_output, result_history_file = launch_irb_with_irbrc_and_irb_history(<<~IRBRC, <<~IRB_HISTORY) do |stdin| + _result_output, result_history_file = launch_irb_with_irbrc_and_irb_history(<<~IRBRC, <<~IRB_HISTORY) do |stdin| IRB.conf[:USE_READLINE] = true IRB.conf[:SAVE_HISTORY] = 100 IRBRC @@ -54,7 +54,7 @@ module TestIRB https://github.com/ruby/ruby/blob/trunk/test/irb/test_history.rb#L54 end def test_history_save_bignum - result_output, result_history_file = launch_irb_with_irbrc_and_irb_history(<<~IRBRC, <<~IRB_HISTORY) do |stdin| + _result_output, result_history_file = launch_irb_with_irbrc_and_irb_history(<<~IRBRC, <<~IRB_HISTORY) do |stdin| IRB.conf[:USE_READLINE] = true IRB.conf[:SAVE_HISTORY] = 10 ** 19 IRBRC @@ -77,7 +77,7 @@ module TestIRB https://github.com/ruby/ruby/blob/trunk/test/irb/test_history.rb#L77 end def test_history_save_minus_as_infinity - result_output, result_history_file = launch_irb_with_irbrc_and_irb_history(<<~IRBRC, <<~IRB_HISTORY) do |stdin| + _result_output, result_history_file = launch_irb_with_irbrc_and_irb_history(<<~IRBRC, <<~IRB_HISTORY) do |stdin| IRB.conf[:USE_READLINE] = true IRB.conf[:SAVE_HISTORY] = -1 # infinity IRBRC -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/