aboutsummaryrefslogtreecommitdiffstats
path: root/spec
diff options
context:
space:
mode:
authorDavid Rodríguez <deivid.rodriguez@riseup.net>2020-06-03 20:46:35 +0200
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2020-06-18 19:14:15 +0900
commit9cc784784979620ea0353c09c778e41146b36d26 (patch)
tree6f9352665ffba790cab0c8c677332a7bcd92ba07 /spec
parent77df7ccc101432a80c7dd6f525dfc4484f6aa898 (diff)
downloadruby-9cc784784979620ea0353c09c778e41146b36d26.tar.gz
s/sys_exec!/sys_exec
Diffstat (limited to 'spec')
-rw-r--r--spec/bundler/commands/binstubs_spec.rb8
-rw-r--r--spec/bundler/commands/newgem_spec.rb2
-rw-r--r--spec/bundler/install/gems/standalone_spec.rb4
-rw-r--r--spec/bundler/quality_spec.rb2
-rw-r--r--spec/bundler/runtime/gem_tasks_spec.rb2
-rw-r--r--spec/bundler/support/path.rb2
-rw-r--r--spec/bundler/support/rubygems_version_manager.rb8
7 files changed, 14 insertions, 14 deletions
diff --git a/spec/bundler/commands/binstubs_spec.rb b/spec/bundler/commands/binstubs_spec.rb
index 14542c6a78..89551d1c39 100644
--- a/spec/bundler/commands/binstubs_spec.rb
+++ b/spec/bundler/commands/binstubs_spec.rb
@@ -120,7 +120,7 @@ RSpec.describe "bundle binstubs <gem>" do
let(:system_bundler_version) { Bundler::VERSION }
it "runs bundler" do
- sys_exec! "bin/bundle install", :env => { "DEBUG" => "1" }
+ sys_exec "bin/bundle install", :env => { "DEBUG" => "1" }
expect(out).to include %(Using bundler #{system_bundler_version}\n)
end
@@ -196,7 +196,7 @@ RSpec.describe "bundle binstubs <gem>" do
before { lockfile.gsub(system_bundler_version, "1.1.1") }
it "calls through to the latest bundler version" do
- sys_exec! "bin/bundle update --bundler", :env => { "DEBUG" => "1" }
+ sys_exec "bin/bundle update --bundler", :env => { "DEBUG" => "1" }
expect(out).to include %(Using bundler #{system_bundler_version}\n)
end
@@ -211,14 +211,14 @@ RSpec.describe "bundle binstubs <gem>" do
context "without a lockfile" do
it "falls back to the latest installed bundler" do
FileUtils.rm bundled_app_lock
- sys_exec! "bin/bundle install", :env => { "DEBUG" => "1" }
+ sys_exec "bin/bundle install", :env => { "DEBUG" => "1" }
expect(out).to include "Using bundler #{system_bundler_version}\n"
end
end
context "using another binstub" do
it "loads all gems" do
- sys_exec! bundled_app("bin/print_loaded_gems").to_s
+ sys_exec bundled_app("bin/print_loaded_gems").to_s
expect(out).to eq %(["bundler-#{Bundler::VERSION}", "prints_loaded_gems-1.0", "rack-1.2"])
end
diff --git a/spec/bundler/commands/newgem_spec.rb b/spec/bundler/commands/newgem_spec.rb
index f5958138e5..3bbd8fab75 100644
--- a/spec/bundler/commands/newgem_spec.rb
+++ b/spec/bundler/commands/newgem_spec.rb
@@ -249,7 +249,7 @@ RSpec.describe "bundle gem" do
load_paths = [lib_dir, spec_dir]
load_path_str = "-I#{load_paths.join(File::PATH_SEPARATOR)}"
- sys_exec! "#{Gem.ruby} #{load_path_str} #{bindir.join("bundle")} gem #{gem_name}", :env => { "PATH" => "" }
+ sys_exec "#{Gem.ruby} #{load_path_str} #{bindir.join("bundle")} gem #{gem_name}", :env => { "PATH" => "" }
end
it "creates the gem without the need for git" do
diff --git a/spec/bundler/install/gems/standalone_spec.rb b/spec/bundler/install/gems/standalone_spec.rb
index 4b31a2f976..d41cffd74a 100644
--- a/spec/bundler/install/gems/standalone_spec.rb
+++ b/spec/bundler/install/gems/standalone_spec.rb
@@ -290,7 +290,7 @@ RSpec.shared_examples "bundle install --standalone" do
skip "exec format error" if Gem.win_platform?
require "tmpdir"
- sys_exec!(%(#{bundled_app("bin/rails")} -v), :dir => Dir.tmpdir)
+ sys_exec(%(#{bundled_app("bin/rails")} -v), :dir => Dir.tmpdir)
expect(out).to eq("2.3.2")
end
@@ -302,7 +302,7 @@ RSpec.shared_examples "bundle install --standalone" do
symlink = File.join(symlink_dir, "rails")
File.symlink(bundled_app("bin/rails"), symlink)
- sys_exec!("#{symlink} -v")
+ sys_exec("#{symlink} -v")
expect(out).to eq("2.3.2")
end
diff --git a/spec/bundler/quality_spec.rb b/spec/bundler/quality_spec.rb
index a266c2008d..d57098be47 100644
--- a/spec/bundler/quality_spec.rb
+++ b/spec/bundler/quality_spec.rb
@@ -235,7 +235,7 @@ RSpec.describe "The library itself" do
files_to_require.reject! {|f| f.start_with?("lib/bundler/vendor") }
files_to_require.map! {|f| File.expand_path(f, source_root) }
files_to_require.sort!
- sys_exec!("ruby -w") do |input, _, _|
+ sys_exec("ruby -w") do |input, _, _|
files_to_require.each do |f|
input.puts "require '#{f}'"
end
diff --git a/spec/bundler/runtime/gem_tasks_spec.rb b/spec/bundler/runtime/gem_tasks_spec.rb
index ced3635149..53515c0d2e 100644
--- a/spec/bundler/runtime/gem_tasks_spec.rb
+++ b/spec/bundler/runtime/gem_tasks_spec.rb
@@ -88,7 +88,7 @@ RSpec.describe "require 'bundler/gem_tasks'" do
it "adds 'pkg' to rake/clean's CLOBBER" do
with_gem_path_as(base_system_gems.to_s) do
- sys_exec! %(#{rake} -e 'load "Rakefile"; puts CLOBBER.inspect'), :env => { "GEM_HOME" => system_gem_path.to_s }
+ sys_exec %(#{rake} -e 'load "Rakefile"; puts CLOBBER.inspect'), :env => { "GEM_HOME" => system_gem_path.to_s }
end
expect(out).to eq '["pkg"]'
end
diff --git a/spec/bundler/support/path.rb b/spec/bundler/support/path.rb
index f56fdfc5aa..042aae92fd 100644
--- a/spec/bundler/support/path.rb
+++ b/spec/bundler/support/path.rb
@@ -240,7 +240,7 @@ module Spec
def git_ls_files(glob)
skip "Not running on a git context, since running tests from a tarball" if ruby_core_tarball?
- sys_exec!("git ls-files -z -- #{glob}", :dir => source_root).split("\x0")
+ sys_exec("git ls-files -z -- #{glob}", :dir => source_root).split("\x0")
end
def tracked_files_glob
diff --git a/spec/bundler/support/rubygems_version_manager.rb b/spec/bundler/support/rubygems_version_manager.rb
index a74cb64337..a7f9fdf2b2 100644
--- a/spec/bundler/support/rubygems_version_manager.rb
+++ b/spec/bundler/support/rubygems_version_manager.rb
@@ -67,8 +67,8 @@ private
def switch_local_copy_if_needed
return unless local_copy_switch_needed?
- sys_exec!("git remote update", :dir => local_copy_path)
- sys_exec!("git checkout #{target_tag} --quiet", :dir => local_copy_path)
+ sys_exec("git remote update", :dir => local_copy_path)
+ sys_exec("git checkout #{target_tag} --quiet", :dir => local_copy_path)
ENV["RGV"] = local_copy_path.to_s
end
@@ -86,7 +86,7 @@ private
end
def local_copy_tag
- sys_exec!("git rev-parse --abbrev-ref HEAD", :dir => local_copy_path)
+ sys_exec("git rev-parse --abbrev-ref HEAD", :dir => local_copy_path)
end
def local_copy_path
@@ -100,7 +100,7 @@ private
unless rubygems_path.directory?
rubygems_path.parent.mkpath
- sys_exec!("git clone https://github.com/rubygems/rubygems.git #{rubygems_path}")
+ sys_exec("git clone https://github.com/rubygems/rubygems.git #{rubygems_path}")
end
rubygems_path