From cca711f34a31bd9e7fd984c474e6fa7a6360c005 Mon Sep 17 00:00:00 2001 From: Hans de Graaff Date: Wed, 2 Apr 2025 14:05:27 +0200 Subject: [PATCH] dev-ruby/actionpack: fix tests Fix tests when chrome and firefox are not present. Making both browsers test dependencies for just a few tests seems excessive. Closes: https://bugs.gentoo.org/952987 Signed-off-by: Hans de Graaff --- dev-ruby/actionpack/actionpack-7.1.5.1.ebuild | 5 +++++ dev-ruby/actionpack/actionpack-7.2.2.1.ebuild | 7 ++++++- dev-ruby/actionpack/actionpack-8.0.2.ebuild | 5 +++++ 3 files changed, 16 insertions(+), 1 deletion(-) diff --git a/dev-ruby/actionpack/actionpack-7.1.5.1.ebuild b/dev-ruby/actionpack/actionpack-7.1.5.1.ebuild index dedecf84035f9..dff4af4fc52cc 100644 --- a/dev-ruby/actionpack/actionpack-7.1.5.1.ebuild +++ b/dev-ruby/actionpack/actionpack-7.1.5.1.ebuild @@ -70,4 +70,9 @@ all_ruby_prepare() { # Avoid tests that fail with a fixed cgi.rb version sed -e '/test_session_store_with_all_domains/askip "Fails with fixed cgi.rb"' \ -i test/dispatch/session/cookie_store_test.rb || die + + # Avoid tests requiring chrome + sed -e '/DrivenBySeleniumWith/,/^end/ s:^:#:' \ + -i test/abstract_unit.rb || die + rm -f test/dispatch/system_testing/{driver,screenshot_helper,system_test_case}_test.rb || die } diff --git a/dev-ruby/actionpack/actionpack-7.2.2.1.ebuild b/dev-ruby/actionpack/actionpack-7.2.2.1.ebuild index 769a68e03a352..e9af7759d41c3 100644 --- a/dev-ruby/actionpack/actionpack-7.2.2.1.ebuild +++ b/dev-ruby/actionpack/actionpack-7.2.2.1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2024 Gentoo Authors +# Copyright 1999-2025 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -71,4 +71,9 @@ all_ruby_prepare() { # Avoid tests that fail with a fixed cgi.rb version sed -e '/test_session_store_with_all_domains/askip "Fails with fixed cgi.rb"' \ -i test/dispatch/session/cookie_store_test.rb || die + + # Avoid tests requiring chrome + sed -e '/DrivenBySeleniumWith/,/^end/ s:^:#:' \ + -i test/abstract_unit.rb || die + rm -f test/dispatch/system_testing/{driver,screenshot_helper,system_test_case}_test.rb || die } diff --git a/dev-ruby/actionpack/actionpack-8.0.2.ebuild b/dev-ruby/actionpack/actionpack-8.0.2.ebuild index d8d938e102ef1..56c12c7423f38 100644 --- a/dev-ruby/actionpack/actionpack-8.0.2.ebuild +++ b/dev-ruby/actionpack/actionpack-8.0.2.ebuild @@ -69,4 +69,9 @@ all_ruby_prepare() { # Avoid tests that fail with a fixed cgi.rb version sed -e '/test_session_store_with_all_domains/askip "Fails with fixed cgi.rb"' \ -i test/dispatch/session/cookie_store_test.rb || die + + # Avoid tests requiring chrome + sed -e '/DrivenBySeleniumWith/,/^end/ s:^:#:' \ + -i test/abstract_unit.rb || die + rm -f test/dispatch/system_testing/{driver,screenshot_helper,system_test_case}_test.rb || die }