[前][次][番号順一覧][スレッド一覧]

ruby-changes:66568

From: Hiroshi <ko1@a...>
Date: Wed, 23 Jun 2021 11:06:19 +0900 (JST)
Subject: [ruby-changes:66568] f2e39e5fed (master): [ruby/rdoc] Update test/rdoc/test_rdoc_rubygems_hook.rb

https://git.ruby-lang.org/ruby.git/commit/?id=f2e39e5fed

From f2e39e5fed498b51ae914ed42ec51ae578330583 Mon Sep 17 00:00:00 2001
From: Hiroshi SHIBATA <hsbt@r...>
Date: Fri, 18 Jun 2021 13:13:27 +0900
Subject: [ruby/rdoc] Update test/rdoc/test_rdoc_rubygems_hook.rb

https://github.com/ruby/rdoc/commit/fb264c4cc4

Co-authored-by: Nobuyoshi Nakada <nobu@r...>
---
 test/rdoc/test_rdoc_rubygems_hook.rb | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/test/rdoc/test_rdoc_rubygems_hook.rb b/test/rdoc/test_rdoc_rubygems_hook.rb
index 4ab7ff0..36794be 100644
--- a/test/rdoc/test_rdoc_rubygems_hook.rb
+++ b/test/rdoc/test_rdoc_rubygems_hook.rb
@@ -21,6 +21,7 @@ class TestRDocRubygemsHook < Test::Unit::TestCase https://github.com/ruby/ruby/blob/trunk/test/rdoc/test_rdoc_rubygems_hook.rb#L21
     @a.instance_variable_set(:@doc_dir, File.join(@tempdir, "doc"))
     @a.instance_variable_set(:@gem_dir, File.join(@tempdir, "a-2"))
     @a.instance_variable_set(:@full_gem_path, File.join(@tempdir, "a-2"))
+    @a.loaded_from = File.join(@tempdir, 'a-2', 'a-2.gemspec')
 
     FileUtils.mkdir_p File.join(@tempdir, 'a-2', 'lib')
     FileUtils.touch   File.join(@tempdir, 'a-2', 'lib', 'a.rb')
@@ -33,9 +34,12 @@ class TestRDocRubygemsHook < Test::Unit::TestCase https://github.com/ruby/ruby/blob/trunk/test/rdoc/test_rdoc_rubygems_hook.rb#L34
     rescue Gem::DocumentError => e
       skip e.message
     end
+    @old_ui = Gem::DefaultUserInteraction.ui
+    Gem::DefaultUserInteraction.ui = Gem::SilentUI.new
   end
 
   def teardown
+    Gem::DefaultUserInteraction.ui = @old_ui
     FileUtils.rm_rf File.expand_path("tmp")
   end
 
-- 
cgit v1.1


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]