Skip to content

Commit 42b0d46

Browse files
soda92matzbot
authored andcommitted
[rubygems/rubygems] move system_gems let commands
ruby/rubygems@1fc1e74f4d
1 parent cabfaa9 commit 42b0d46

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

spec/bundler/commands/exec_spec.rb

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
# frozen_string_literal: true
22

33
RSpec.describe "bundle exec" do
4-
let(:system_gems_to_install) { %w[myrack-1.0.0 myrack-0.9.1] }
5-
64
it "works with --gemfile flag" do
7-
system_gems(system_gems_to_install, path: default_bundle_path)
5+
system_gems(%w[myrack-1.0.0 myrack-0.9.1], path: default_bundle_path)
86

97
gemfile "CustomGemfile", <<-G
108
source "https://gem.repo1"
@@ -16,7 +14,7 @@
1614
end
1715

1816
it "activates the correct gem" do
19-
system_gems(system_gems_to_install, path: default_bundle_path)
17+
system_gems(%w[myrack-1.0.0 myrack-0.9.1], path: default_bundle_path)
2018

2119
gemfile <<-G
2220
source "https://gem.repo1"
@@ -28,7 +26,7 @@
2826
end
2927

3028
it "works and prints no warnings when HOME is not writable" do
31-
system_gems(system_gems_to_install, path: default_bundle_path)
29+
system_gems(%w[myrack-1.0.0 myrack-0.9.1], path: default_bundle_path)
3230

3331
gemfile <<-G
3432
source "https://gem.repo1"
@@ -386,7 +384,7 @@
386384
end
387385

388386
it "raises a helpful error when exec'ing to something outside of the bundle" do
389-
system_gems(system_gems_to_install, path: default_bundle_path)
387+
system_gems(%w[myrack-1.0.0 myrack-0.9.1], path: default_bundle_path)
390388

391389
bundle "config set clean false" # want to keep the myrackup binstub
392390
install_gemfile <<-G
@@ -725,7 +723,7 @@ def bin_path(a,b,c)
725723
RUBY
726724

727725
before do
728-
system_gems(system_gems_to_install, path: default_bundle_path)
726+
system_gems(%w[myrack-1.0.0 myrack-0.9.1], path: default_bundle_path)
729727

730728
bundled_app(path).open("w") {|f| f << executable }
731729
bundled_app(path).chmod(0o755)

0 commit comments

Comments
 (0)