From 276c82b5e84829f579f0bdfb3ce59fad8c85f6a4 Mon Sep 17 00:00:00 2001 From: Samuel Giddins Date: Fri, 31 Mar 2017 11:26:35 -0500 Subject: [Outdated] Support running when gems are not yet installed --- lib/bundler/cli/outdated.rb | 2 +- spec/commands/outdated_spec.rb | 15 +++++++++++++++ 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/lib/bundler/cli/outdated.rb b/lib/bundler/cli/outdated.rb index 93e50b10b6..9050126cd1 100644 --- a/lib/bundler/cli/outdated.rb +++ b/lib/bundler/cli/outdated.rb @@ -20,7 +20,7 @@ module Bundler end Bundler.definition.validate_runtime! - current_specs = Bundler.ui.silence { Bundler.load.specs } + current_specs = Bundler.ui.silence { Bundler.definition.resolve } current_dependencies = {} Bundler.ui.silence do Bundler.load.dependencies.each do |dep| diff --git a/spec/commands/outdated_spec.rb b/spec/commands/outdated_spec.rb index b927a0be2b..c6b6c9f59e 100644 --- a/spec/commands/outdated_spec.rb +++ b/spec/commands/outdated_spec.rb @@ -489,6 +489,21 @@ RSpec.describe "bundle outdated" do it_behaves_like "version update is detected" end + context "when on a new machine" do + before do + simulate_new_machine + + update_git "foo", :path => lib_path("foo") + update_repo2 do + build_gem "activesupport", "3.3.5" + build_gem "weakling", "0.8.0" + end + end + + subject { bundle "outdated" } + it_behaves_like "version update is detected" + end + shared_examples_for "minor version updates are detected" do before do update_repo2 do -- cgit v1.2.1