diff options
author | David RodrÃguez <deivid.rodriguez@riseup.net> | 2022-05-25 11:03:33 +0200 |
---|---|---|
committer | git <svn-admin@ruby-lang.org> | 2022-05-27 17:26:22 +0900 |
commit | 6778d321a7fa0ec56e3e02b6f3739a035c7ef41a (patch) | |
tree | 278712da8c20b1ba77762570756ff85a1856e74f /spec/bundler/commands/install_spec.rb | |
parent | 45177129a75c5bfd03933b82076e8dc49acc500f (diff) |
[rubygems/rubygems] Show better error when previous installation fails to be removed
Instead of guessing on the culprit.
We actually have a helper, `Bundler.rm_rf`, with exactly the behavior
that we want:
* Allow the passed folder to not exist.
* No exception swallowing other than that.
https://github.com/rubygems/rubygems/commit/5fa3e6f04a
Diffstat (limited to 'spec/bundler/commands/install_spec.rb')
-rw-r--r-- | spec/bundler/commands/install_spec.rb | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/spec/bundler/commands/install_spec.rb b/spec/bundler/commands/install_spec.rb index f189a70b10..07585237e3 100644 --- a/spec/bundler/commands/install_spec.rb +++ b/spec/bundler/commands/install_spec.rb @@ -755,12 +755,8 @@ RSpec.describe "bundle install with gem sources" do end expect(err).not_to include("ERROR REPORT TEMPLATE") - - expect(err).to include( - "There was an error while trying to delete `#{foo_path}`. " \ - "It is likely that you need to grant executable permissions for all parent directories " \ - "and write permissions for `#{gems_path}`, and the same thing for all subdirectories inside #{foo_path}." - ) + expect(err).to include("Could not delete previous installation of `#{foo_path}`.") + expect(err).to include("The underlying error was Errno::EACCES") end end |