ruby-changes:66180
From: Hiroshi <ko1@a...>
Date: Wed, 12 May 2021 17:25:27 +0900 (JST)
Subject: [ruby-changes:66180] 00f5b4b546 (master): [rubygems/rubygems] Don't use Minitest::Mock
https://git.ruby-lang.org/ruby.git/commit/?id=00f5b4b546 From 00f5b4b54614d28941fd31f93eaf36357bd8c099 Mon Sep 17 00:00:00 2001 From: Hiroshi SHIBATA <hsbt@r...> Date: Tue, 11 May 2021 16:31:18 +0900 Subject: [rubygems/rubygems] Don't use Minitest::Mock https://github.com/rubygems/rubygems/commit/d3fa893597 --- test/rubygems/test_gem_commands_open_command.rb | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/test/rubygems/test_gem_commands_open_command.rb b/test/rubygems/test_gem_commands_open_command.rb index d33a14e..2c32b81 100644 --- a/test/rubygems/test_gem_commands_open_command.rb +++ b/test/rubygems/test_gem_commands_open_command.rb @@ -25,16 +25,15 @@ class TestGemCommandsOpenCommand < Gem::TestCase https://github.com/ruby/ruby/blob/trunk/test/rubygems/test_gem_commands_open_command.rb#L25 gem 'foo', '1.0.0' spec = gem 'foo', '1.0.1' - mock = Minitest::Mock.new - mock.expect(:call, true, [spec.full_gem_path]) - Dir.stub(:chdir, mock) do - use_ui @ui do - @cmd.execute + assert_nothing_raised Gem::MockGemUi::TermError do + Dir.stub(:chdir, spec.full_gem_path) do + use_ui @ui do + @cmd.execute + end end end - assert mock.verify assert_equal "", @ui.error end -- cgit v1.1 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/