mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-11-20 22:27:17 -08:00
dev-ruby/bogus: fix against erb-6
Closes: https://bugs.gentoo.org/978454 Signed-off-by: Alfred Wingate <parona@protonmail.com> Part-of: https://codeberg.org/gentoo/gentoo/pulls/1527 Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
# Copyright 1999-2025 Gentoo Authors
|
||||
# Copyright 1999-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
USE_RUBY="ruby31 ruby32 ruby33 ruby34"
|
||||
USE_RUBY="ruby32 ruby33 ruby34"
|
||||
|
||||
RUBY_FAKEGEM_RECIPE_TEST="rspec3"
|
||||
|
||||
@@ -21,6 +21,10 @@ KEYWORDS="~amd64"
|
||||
|
||||
ruby_add_rdepend ">=dev-ruby/dependor-0.0.4"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/bogus-0.1.7-erb6.patch
|
||||
)
|
||||
|
||||
all_ruby_prepare() {
|
||||
sed -i -e '/simplecov/,/^end/ s:^:#:' \
|
||||
-e '/SimpleCov/,/^end/ s:^:#:' spec/spec_helper.rb || die
|
||||
@@ -0,0 +1,15 @@
|
||||
https://github.com/ruby/erb/pull/95
|
||||
|
||||
diff --git a/lib/bogus/stubbing/not_all_expectations_satisfied.rb b/lib/bogus/stubbing/not_all_expectations_satisfied.rb
|
||||
index e358beb..af67652 100644
|
||||
--- a/lib/bogus/stubbing/not_all_expectations_satisfied.rb
|
||||
+++ b/lib/bogus/stubbing/not_all_expectations_satisfied.rb
|
||||
@@ -15,7 +15,7 @@ module Bogus
|
||||
<% end %>
|
||||
EOF
|
||||
str = str.gsub(/ {6}/, '')
|
||||
- template = ERB.new(str, nil, "<>")
|
||||
+ template = ERB.new(str, trim_mode: "<>")
|
||||
new(template.result(binding))
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user