summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Rodríguez <deivid.rodriguez@riseup.net>2025-07-15 14:36:31 +0200
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2025-09-03 23:38:37 +0900
commitd20936c9f59a5be8f4de6057d47cbc417111b0ca (patch)
treec842ba42fbad6c983d316cf528cc16b7475b3de8
parent1c7c0107a465b0f37d07a3aa5dc43b5427a1380a (diff)
[rubygems/rubygems] Improve `deprecations` helper
Previous implementation included an empty element in the list of deprecations. https://github.com/rubygems/rubygems/commit/59eb233039
-rw-r--r--spec/bundler/support/helpers.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/spec/bundler/support/helpers.rb b/spec/bundler/support/helpers.rb
index 438037e08c..17c38c7760 100644
--- a/spec/bundler/support/helpers.rb
+++ b/spec/bundler/support/helpers.rb
@@ -39,7 +39,7 @@ module Spec
end
def deprecations
- err.split("\n").select {|l| l =~ MAJOR_DEPRECATION }.join("\n").split(MAJOR_DEPRECATION)
+ err.split("\n").filter_map {|l| l.sub(MAJOR_DEPRECATION, "") if l.match?(MAJOR_DEPRECATION) }
end
def run(cmd, *args)