Skip to content

Commit

Permalink
(deprecation) switched from 'bundle show' to 'bundle info', get rid o…
Browse files Browse the repository at this point in the history
…f deprecation-warning
  • Loading branch information
tkplista committed Jan 14, 2020
1 parent 6e0238d commit 5473259
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/parallel_tests/rspec/runner.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def determine_executable
when File.exist?("bin/rspec")
ParallelTests.with_ruby_binary("bin/rspec")
when ParallelTests.bundler_enabled?
cmd = (run("bundle show rspec-core") =~ %r{Could not find gem.*} ? "spec" : "rspec")
cmd = (run("bundle info rspec-core") =~ %r{Could not find gem.*} ? "spec" : "rspec")
"bundle exec #{cmd}"
else
%w[spec rspec].detect{|cmd| system "#{cmd} --version > #{DEV_NULL} 2>&1" }
Expand Down
2 changes: 1 addition & 1 deletion spec/parallel_tests/rspec/runner_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def call(*args)
expect(File).to receive(:file?).with('spec/parallel_spec.opts').and_return true

allow(ParallelTests).to receive(:bundler_enabled?).and_return true
allow(ParallelTests::RSpec::Runner).to receive(:run).with("bundle show rspec-core").and_return "/foo/bar/rspec-core-2.4.2"
allow(ParallelTests::RSpec::Runner).to receive(:run).with("bundle info rspec-core").and_return "/foo/bar/rspec-core-2.4.2"

should_run_with %r{rspec\s+(--color --tty )?-O spec/parallel_spec.opts}
call('xxx', 1, 22, {})
Expand Down

0 comments on commit 5473259

Please sign in to comment.