summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2020-01-28 13:52:35 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2020-01-28 22:09:23 +0900
commit24025e4ae25544fc9343c563f3f94bc2965c3b40 (patch)
treeedc9a87c007709b302800e383ac7bc1c09e4bd47 /spec
parenta45a7e778b04edfff03d6dd2f78a2db649d3805a (diff)
downloadbundler-24025e4ae25544fc9343c563f3f94bc2965c3b40.tar.gz
Simplify arguments to `sh`
Get rid of escaping and splitting shell code repeatedly.
Diffstat (limited to 'spec')
-rw-r--r--spec/bundler/gem_helper_spec.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/spec/bundler/gem_helper_spec.rb b/spec/bundler/gem_helper_spec.rb
index 6af78e00be..10ea36e866 100644
--- a/spec/bundler/gem_helper_spec.rb
+++ b/spec/bundler/gem_helper_spec.rb
@@ -231,7 +231,8 @@ RSpec.describe Bundler::GemHelper do
end
it "uses Kernel.system" do
- expect(Kernel).to receive(:system).with(gem_bin, "push", app_gem_path.to_s, "--host", "http://example.org").and_return(true)
+ cmd = gem_bin.shellsplit
+ expect(Kernel).to receive(:system).with(*cmd, "push", app_gem_path.to_s, "--host", "http://example.org").and_return(true)
Rake.application["release"].invoke
end