Skip to content

Commit d3fa893

Browse files
committed
Don't use Minitest::Mock
1 parent f1af59f commit d3fa893

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

test/rubygems/test_gem_commands_open_command.rb

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,16 +25,15 @@ def test_execute
2525

2626
gem 'foo', '1.0.0'
2727
spec = gem 'foo', '1.0.1'
28-
mock = Minitest::Mock.new
29-
mock.expect(:call, true, [spec.full_gem_path])
3028

31-
Dir.stub(:chdir, mock) do
32-
use_ui @ui do
33-
@cmd.execute
29+
assert_nothing_raised Gem::MockGemUi::TermError do
30+
Dir.stub(:chdir, spec.full_gem_path) do
31+
use_ui @ui do
32+
@cmd.execute
33+
end
3434
end
3535
end
3636

37-
assert mock.verify
3837
assert_equal "", @ui.error
3938
end
4039

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy