mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
[bundler/bundler] [Package] Always resolve remotely for --all-platforms
https://github.com/bundler/bundler/commit/e45d2272ea
This commit is contained in:
parent
2ccb3db5fb
commit
d761a0f6ff
2 changed files with 20 additions and 1 deletions
|
@ -296,7 +296,7 @@ module Bundler
|
||||||
|
|
||||||
# returns whether or not a re-resolve was needed
|
# returns whether or not a re-resolve was needed
|
||||||
def resolve_if_needed(options)
|
def resolve_if_needed(options)
|
||||||
if !@definition.unlocking? && !options["force"] && !Bundler.settings[:inline] && Bundler.default_lockfile.file?
|
if !@definition.unlocking? && !options["force"] && !options["all-platforms"] && !Bundler.settings[:inline] && Bundler.default_lockfile.file?
|
||||||
return false if @definition.nothing_changed? && !@definition.missing_specs?
|
return false if @definition.nothing_changed? && !@definition.missing_specs?
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -203,6 +203,25 @@ RSpec.describe "bundle package" do
|
||||||
bundle "package --all-platforms"
|
bundle "package --all-platforms"
|
||||||
expect(bundled_app("vendor/cache/rack-1.0.0.gem")).to exist
|
expect(bundled_app("vendor/cache/rack-1.0.0.gem")).to exist
|
||||||
end
|
end
|
||||||
|
|
||||||
|
it "does not attempt to install gems in without groups" do
|
||||||
|
install_gemfile! <<-G, forgotten_command_line_options(:without => "wo")
|
||||||
|
source "file:#{gem_repo1}"
|
||||||
|
gem "rack"
|
||||||
|
group :wo do
|
||||||
|
gem "weakling"
|
||||||
|
end
|
||||||
|
G
|
||||||
|
|
||||||
|
bundle! :package, "all-platforms" => true
|
||||||
|
expect(bundled_app("vendor/cache/weakling-0.0.3.gem")).to exist
|
||||||
|
expect(the_bundle).to include_gem "rack 1.0"
|
||||||
|
expect(the_bundle).not_to include_gem "weakling"
|
||||||
|
|
||||||
|
bundle! :install, forgotten_command_line_options(:without => "wo")
|
||||||
|
expect(the_bundle).to include_gem "rack 1.0"
|
||||||
|
expect(the_bundle).not_to include_gem "weakling"
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
context "with --frozen" do
|
context "with --frozen" do
|
||||||
|
|
Loading…
Add table
Reference in a new issue