diff options
| -rw-r--r-- | lib/bundler/spec_set.rb | 2 | ||||
| -rw-r--r-- | spec/bundler/lock/lockfile_spec.rb | 2 | ||||
| -rw-r--r-- | spec/bundler/support/platforms.rb | 6 |
3 files changed, 8 insertions, 2 deletions
diff --git a/lib/bundler/spec_set.rb b/lib/bundler/spec_set.rb index 08f523312c..4882f7b38a 100644 --- a/lib/bundler/spec_set.rb +++ b/lib/bundler/spec_set.rb @@ -101,6 +101,8 @@ module Bundler end def incomplete_ruby_specs?(deps) + return false if @specs.empty? + self.for(deps, true, [Gem::Platform::RUBY]) @incomplete_specs.any? diff --git a/spec/bundler/lock/lockfile_spec.rb b/spec/bundler/lock/lockfile_spec.rb index dd656ae022..78130d8f15 100644 --- a/spec/bundler/lock/lockfile_spec.rb +++ b/spec/bundler/lock/lockfile_spec.rb @@ -1262,7 +1262,7 @@ RSpec.describe "the lockfile format" do indirect_dependency (1.2.3) PLATFORMS - #{lockfile_platforms} + #{formatted_lockfile_platforms(*["ruby", generic_local_platform].uniq)} DEPENDENCIES direct_dependency diff --git a/spec/bundler/support/platforms.rb b/spec/bundler/support/platforms.rb index 89a8d45ffd..eca1b2e60d 100644 --- a/spec/bundler/support/platforms.rb +++ b/spec/bundler/support/platforms.rb @@ -96,7 +96,11 @@ module Spec end def lockfile_platforms(*extra) - [local_platform, *extra].map(&:to_s).sort.join("\n ") + formatted_lockfile_platforms(local_platform, *extra) + end + + def formatted_lockfile_platforms(*platforms) + platforms.map(&:to_s).sort.join("\n ") end end end |
