aboutsummaryrefslogtreecommitdiffstats
path: root/spec
diff options
context:
space:
mode:
authorDEVRAJ KUMAR <43830009+devraj-kumar@users.noreply.github.com>2020-04-11 03:50:19 +0530
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2020-06-05 07:32:42 +0900
commit9139acca66086d0d6c0867ff02b8cb8c338df5d4 (patch)
tree7c02ee995afd64e3467d1e9f799355de70c58841 /spec
parentf0ae5ac3135a6cf26666ec6ba33d34a738df7573 (diff)
downloadruby-9139acca66086d0d6c0867ff02b8cb8c338df5d4.tar.gz
[rubygems/rubygems] Fix `bundle info` not indicating a gem which has been deleted, unlike `bundle show`
Co-Authored-By: David Rodríguez <deivid.rodriguez@riseup.net> https://github.com/rubygems/rubygems/commit/2851b40ffb
Diffstat (limited to 'spec')
-rw-r--r--spec/bundler/commands/info_spec.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/spec/bundler/commands/info_spec.rb b/spec/bundler/commands/info_spec.rb
index df2d5f2824..bf18395ba6 100644
--- a/spec/bundler/commands/info_spec.rb
+++ b/spec/bundler/commands/info_spec.rb
@@ -41,6 +41,15 @@ RSpec.describe "bundle info" do
expect(err).to eq("Could not find gem 'missing'.")
end
+ it "warns if path no longer exists on disk" do
+ FileUtils.rm_rf(default_bundle_path("gems", "rails-2.3.2"))
+
+ bundle "info rails --path"
+
+ expect(err).to match(/has been deleted/i)
+ expect(err).to match(default_bundle_path("gems", "rails-2.3.2").to_s)
+ end
+
context "given a default gem shippped in ruby", :ruby_repo do
it "prints information about the default gem" do
bundle! "info rdoc"