summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans de Graaff <graaff@gentoo.org>2022-07-28 17:58:44 +0200
committerHans de Graaff <graaff@gentoo.org>2022-07-29 06:48:50 +0200
commit61cd85a5c6f9fbaa2d98c016329e50323b7fa61f (patch)
tree8b300fad89604be08198503971a3bbcb9ed487c8 /dev-ruby/multi_json
parentdev-ruby/faraday-net_http: also allow faraday:2 (diff)
downloadgentoo-61cd85a5c6f9fbaa2d98c016329e50323b7fa61f.tar.gz
gentoo-61cd85a5c6f9fbaa2d98c016329e50323b7fa61f.tar.bz2
gentoo-61cd85a5c6f9fbaa2d98c016329e50323b7fa61f.zip
dev-ruby/multi_json: enable ruby31, fix tests
Closes: https://bugs.gentoo.org/835621 Signed-off-by: Hans de Graaff <graaff@gentoo.org>
Diffstat (limited to 'dev-ruby/multi_json')
-rw-r--r--dev-ruby/multi_json/multi_json-1.15.0.ebuild11
1 files changed, 10 insertions, 1 deletions
diff --git a/dev-ruby/multi_json/multi_json-1.15.0.ebuild b/dev-ruby/multi_json/multi_json-1.15.0.ebuild
index 8c7cefde22b4..45edc1cfd08d 100644
--- a/dev-ruby/multi_json/multi_json-1.15.0.ebuild
+++ b/dev-ruby/multi_json/multi_json-1.15.0.ebuild
@@ -3,7 +3,7 @@
EAPI=7
-USE_RUBY="ruby25 ruby26 ruby27 ruby30"
+USE_RUBY="ruby26 ruby27 ruby30 ruby31"
RUBY_FAKEGEM_RECIPE_TEST="rspec3"
RUBY_FAKEGEM_TASK_DOC="yard"
@@ -53,6 +53,15 @@ all_ruby_prepare() {
# Avoid testing unpackaged adapters
rm spec/{gson,nsjsonserialization,jr_jackson,oj}_adapter_spec.rb || die
+
+ # Fix expectations confused by ruby30 kwargs
+ sed -e "/expect/ s/:foo => 'bar', :fizz => 'buzz'/{:foo => 'bar', :fizz => 'buzz'}/" \
+ -e "/expect/ s/:bar => :baz/{:bar => :baz}/" \
+ -i spec/shared/adapter.rb || die
+ sed -e '/expect/ s/:indent => "\\t"/{:indent => "\t"}/' \
+ -e '/expect/ s/:quirks_mode => false, :create_additions => false/{:quirks_mode => false, :create_additions => false}/' \
+ -i spec/shared/json_common_adapter.rb || die
+ sed -e "/expect/ s/:foo => 'bar'/{:foo => 'bar'}/" -i spec/multi_json_spec.rb || die
}
each_ruby_test() {