summaryrefslogtreecommitdiff
path: root/spec/bundler
diff options
context:
space:
mode:
authorDavid Rodríguez <deivid.rodriguez@riseup.net>2022-08-01 17:11:20 +0200
committergit <svn-admin@ruby-lang.org>2022-08-03 16:33:53 +0900
commit851b3aa7dde489502f517cc1ad9d31d9a3056197 (patch)
treea9c6a9a86e8da3ae5ccb283f8b8b86db431dce61 /spec/bundler
parent35c65e7ba6b4aa8bc80aaca8429a48c4eb923b89 (diff)
[rubygems/rubygems] Fix `bundle outdated --strict`
It should be an alias of `--filter-strict`. `--update-strict` is essentially a dummy option with no special behavior associated and should be deprecated. https://github.com/rubygems/rubygems/commit/ec1e5d83c8
Diffstat (limited to 'spec/bundler')
-rw-r--r--spec/bundler/commands/outdated_spec.rb16
1 files changed, 16 insertions, 0 deletions
diff --git a/spec/bundler/commands/outdated_spec.rb b/spec/bundler/commands/outdated_spec.rb
index 6b7c95f01b..e084af85d7 100644
--- a/spec/bundler/commands/outdated_spec.rb
+++ b/spec/bundler/commands/outdated_spec.rb
@@ -604,6 +604,22 @@ RSpec.describe "bundle outdated" do
expect(out).to end_with(expected_output)
end
+ it "only reports gems that have a newer version that matches the specified dependency version requirements, using --strict alias" do
+ update_repo2 do
+ build_gem "activesupport", "3.0"
+ build_gem "weakling", "0.0.5"
+ end
+
+ bundle :outdated, :strict => true, :raise_on_error => false
+
+ expected_output = <<~TABLE.strip
+ Gem Current Latest Requested Groups
+ weakling 0.0.3 0.0.5 ~> 0.0.1 default
+ TABLE
+
+ expect(out).to end_with(expected_output)
+ end
+
it "doesn't crash when some deps unused on the current platform" do
install_gemfile <<-G
source "#{file_uri_for(gem_repo2)}"