diff --git a/Library/Homebrew/test/cask/pkg_spec.rb b/Library/Homebrew/test/cask/pkg_spec.rb index ad370d4055..7556040f69 100644 --- a/Library/Homebrew/test/cask/pkg_spec.rb +++ b/Library/Homebrew/test/cask/pkg_spec.rb @@ -4,7 +4,13 @@ describe Cask::Pkg, :cask do describe "#uninstall" do let(:fake_system_command) { NeverSudoSystemCommand } - let(:empty_response) { double(stdout: "", plist: { "volume" => "/", "install-location" => "", "paths" => {} }) } + let(:empty_response) do + instance_double( + SystemCommand::Result, + stdout: "", + plist: { "volume" => "/", "install-location" => "", "paths" => {} }, + ) + end let(:pkg) { described_class.new("my.fake.pkg", fake_system_command) } it "removes files and dirs referenced by the pkg" do