ruby-changes:55457
From: naruse <ko1@a...>
Date: Sun, 21 Apr 2019 14:48:42 +0900 (JST)
Subject: [ruby-changes:55457] naruse:r67678 (trunk): suppress warning in test/irb
naruse 2019-04-21 14:48:35 +0900 (Sun, 21 Apr 2019) New Revision: 67678 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=67678 Log: suppress warning in test/irb https://rubyci.org/logs/rubyci.s3.amazonaws.com/centos7/ruby-trunk/log/20190421T040003Z.fail.html.gz Modified files: trunk/test/irb/test_context.rb trunk/test/irb/test_raise_no_backtrace_exception.rb Index: test/irb/test_context.rb =================================================================== --- test/irb/test_context.rb (revision 67677) +++ test/irb/test_context.rb (revision 67678) @@ -55,6 +55,7 @@ module TestIRB https://github.com/ruby/ruby/blob/trunk/test/irb/test_context.rb#L55 end def test_eval_input + verbose, $VERBOSE = $VERBOSE, nil input = TestInputMethod.new([ "raise 'Foo'\n", "_\n", @@ -71,6 +72,8 @@ module TestIRB https://github.com/ruby/ruby/blob/trunk/test/irb/test_context.rb#L72 :*, /0$/, :*, /0$/, /\s*/], out) + ensure + $VERBOSE = verbose end end end Index: test/irb/test_raise_no_backtrace_exception.rb =================================================================== --- test/irb/test_raise_no_backtrace_exception.rb (revision 67677) +++ test/irb/test_raise_no_backtrace_exception.rb (revision 67678) @@ -4,7 +4,7 @@ require 'test/unit' https://github.com/ruby/ruby/blob/trunk/test/irb/test_raise_no_backtrace_exception.rb#L4 module TestIRB class TestRaiseNoBacktraceException < Test::Unit::TestCase def test_raise_exception - status = assert_in_out_err(%w[-rirb -e IRB.start(__FILE__) -- -f --], <<-IRB, /Exception: foo/, []) + status = assert_in_out_err(%w[-rirb -W1 -e IRB.start(__FILE__) -- -f --], <<-IRB, /Exception: foo/, []) e = Exception.new("foo") def e.backtrace; nil; end raise e -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/