[rubygems/rubygems] The simulate_platform
helper can take a string
https://github.com/rubygems/rubygems/commit/680bafac1a
This commit is contained in:
parent
cf6efd1bb7
commit
997642cfbd
@ -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. " \
|
||||
|
@ -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)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user