diff options
| author | David RodrÃguez <deivid.rodriguez@riseup.net> | 2024-07-25 18:58:45 +0200 |
|---|---|---|
| committer | git <svn-admin@ruby-lang.org> | 2024-07-30 14:02:02 +0000 |
| commit | 997642cfbdaa59fe900e3177d26cb35bf8f767e2 (patch) | |
| tree | 313e84f764703c508276a8f60a78e5e538503722 | |
| parent | cf6efd1bb77907825bb42ea305214ef415ae3382 (diff) | |
[rubygems/rubygems] The `simulate_platform` helper can take a string
https://github.com/rubygems/rubygems/commit/680bafac1a
| -rw-r--r-- | spec/bundler/commands/install_spec.rb | 2 | ||||
| -rw-r--r-- | spec/bundler/commands/lock_spec.rb | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/spec/bundler/commands/install_spec.rb b/spec/bundler/commands/install_spec.rb index 1c00e6fe6e..bff7fd8460 100644 --- a/spec/bundler/commands/install_spec.rb +++ b/spec/bundler/commands/install_spec.rb @@ -1170,7 +1170,7 @@ RSpec.describe "bundle install with gem sources" do end it "should fail loudly if the lockfile platforms don't include the current platform" do - simulate_platform(Gem::Platform.new("x86_64-linux")) { bundle "install", raise_on_error: false } + simulate_platform("x86_64-linux") { bundle "install", raise_on_error: false } expect(err).to eq( "Your bundle only supports platforms [\"x86_64-darwin-19\"] but your local platform is x86_64-linux. " \ diff --git a/spec/bundler/commands/lock_spec.rb b/spec/bundler/commands/lock_spec.rb index fdba96c5e1..a540092c59 100644 --- a/spec/bundler/commands/lock_spec.rb +++ b/spec/bundler/commands/lock_spec.rb @@ -1061,7 +1061,7 @@ RSpec.describe "bundle lock" do #{Bundler::VERSION} G - simulate_platform(Gem::Platform.new("x86_64-darwin-19")) { bundle "lock --update" } + simulate_platform("x86_64-darwin-19") { bundle "lock --update" } expect(out).to match(/Writing lockfile to.+Gemfile\.lock/) end @@ -1083,7 +1083,7 @@ RSpec.describe "bundle lock" do gem "libv8" G - simulate_platform(Gem::Platform.new("x86_64-darwin-19")) { bundle "lock" } + simulate_platform("x86_64-darwin-19") { bundle "lock" } checksums = checksums_section_when_enabled do |c| c.checksum gem_repo4, "libv8", "8.4.255.0", "x86_64-darwin-19" @@ -1151,7 +1151,7 @@ RSpec.describe "bundle lock" do previous_lockfile = lockfile %w[x86_64-darwin-19 x86_64-darwin-20].each do |platform| - simulate_platform(Gem::Platform.new(platform)) do + simulate_platform(platform) do bundle "lock" expect(lockfile).to eq(previous_lockfile) |
