public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/rubygem-railties] rawhide: Properly patch ActiveStorage analyzers integration tests.
@ 2026-08-05 13:49 
  0 siblings, 0 replies; only message in thread
From:  @ 2026-08-05 13:49 UTC (permalink / raw)
  To: git-commits

A new commit has been pushed.

Repo   : rpms/rubygem-railties
Branch : rawhide
Commit : 6250a5e12109bd6d61a69049e0795c136aef93ef
Author : Vít Ondruch <vondruch@redhat.com>
Date   : 2026-08-05T15:01:19+02:00
Stats  : +39/-5 in 2 file(s)
URL    : https://src.fedoraproject.org/rpms/rubygem-railties/c/6250a5e12109bd6d61a69049e0795c136aef93ef?branch=rawhide

Log:
Properly patch ActiveStorage analyzers integration tests.

---
diff --git a/rubygem-railties-8.1.3.1-Use-local-fixtures.patch b/rubygem-railties-8.1.3.1-Use-local-fixtures.patch
new file mode 100644
index 0000000..825e919
--- /dev/null
+++ b/rubygem-railties-8.1.3.1-Use-local-fixtures.patch
@@ -0,0 +1,24 @@
+From 0167721c073c8f43d5dddc6c4a656f787cc05f5c Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?V=C3=ADt=20Ondruch?= <vondruch@redhat.com>
+Date: Mon, 3 Aug 2026 16:01:05 +0200
+Subject: [PATCH] Use local fixtures
+
+This helps with testing Railties in isolation from other parts of the
+framework, similarly to #54864.
+---
+ .../application/active_storage/analyzers_integration_test.rb    | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/railties/test/application/active_storage/analyzers_integration_test.rb b/railties/test/application/active_storage/analyzers_integration_test.rb
+index df0d0249bcf..50f538781fd 100644
+--- a/railties/test/application/active_storage/analyzers_integration_test.rb
++++ b/railties/test/application/active_storage/analyzers_integration_test.rb
+@@ -8,7 +8,7 @@ class ActiveStorageEngineTest < ActiveSupport::TestCase
+ 
+     include ActiveJob::TestHelper
+ 
+-    self.file_fixture_path = "#{RAILS_FRAMEWORK_ROOT}/activestorage/test/fixtures/files"
++    self.file_fixture_path = "test/fixtures/files"
+ 
+     def setup
+       build_app

diff --git a/rubygem-railties.spec b/rubygem-railties.spec
index f0449df..8f31201 100644
--- a/rubygem-railties.spec
+++ b/rubygem-railties.spec
@@ -6,7 +6,7 @@
 
 Name: rubygem-%{gem_name}
 Version: 8.1.3.1
-Release: 1%{?dist}
+Release: 2%{?dist}
 Summary: Tools for creating, working with, and running Rails applications
 License: MIT
 URL: https://rubyonrails.org
@@ -22,6 +22,16 @@ Source1: %{gem_name}-%{version}%{?prerelease}-tests.tar.gz
 # ~~~
 # https://github.com/rails/rails/pull/58148
 Patch0: rubygem-railties-8.1.3-Fix-test_precompile_shouldnt_use_the_digests_present_in_manifest-json-failure.patch
+# Use local fixtures to fix test errors such as:
+# ~~~
+#   1) Error:
+# ApplicationTests::ActiveStorageEngineTest#test_analyzers_not_empty:
+# ArgumentError: the directory '/builddir/build/BUILD/rubygem-railties-8.1.2-build/railties-8.1.2/usr/share/gems/gems/activestorage/test/fixtures/files' does not contain a file named 'racecar.jpg'
+#     /usr/share/gems/gems/activesupport-8.1.2/lib/active_support/testing/file_fixtures.rb:33:in 'ActiveSupport::Testing::FileFixtures#file_fixture'
+#     test/application/active_storage/analyzers_integration_test.rb:53:in 'ApplicationTests::ActiveStorageEngineTest#test_analyzers_not_empty'
+# ~~~
+# https://github.com/rails/rails/pull/58360
+Patch1: rubygem-railties-8.1.3.1-Use-local-fixtures.patch
 
 # dbconsole requires the executable.
 Suggests: %{_bindir}/sqlite3
@@ -97,6 +107,7 @@ Documentation for %{name}.
 
 ( cd %{builddir}
 %patch 0 -p2
+%patch 1 -p2
 )
 
 %build
@@ -262,10 +273,6 @@ sed -i -r '/with_new_plugin\(/ s/\)/, "--skip-rubocop")/' \
 sed -i -r '/generate_plugin\(/ s/\)$/, "--skip-rubocop")/' \
   test/generators/test_runner_in_engine_test.rb
 
-# This would deserve similar upstream fix as:
-# https://github.com/rails/rails/pull/54864
-sed -i '/file_fixture_path/ s|".*"|"test/fixtures/files"|' test/application/active_storage/analyzers_integration_test.rb
-
 # Tests needs to be executed in isolation. Also, use `bundle exec`, there
 # is nothing to loose here and some tests depends on the Bundler (e.g.
 # test/generators/app_generator_test.rb).
@@ -301,6 +308,9 @@ rm -rf ${PG_DIR}
 %doc %{gem_instdir}/README.rdoc
 
 %changelog
+* Wed Aug 05 2026 Vít Ondruch <vondruch@redhat.com> - 8.1.3.1-2
+- Properly patch ActiveStorage analyzers integration tests.
+
 * Mon Aug 03 2026 Vít Ondruch <vondruch@redhat.com> - 8.1.3.1-1
 - Update to Railties 8.1.3.1.
   Related: rhzb#2405582

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2026-08-05 13:49 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-08-05 13:49 [rpms/rubygem-railties] rawhide: Properly patch ActiveStorage analyzers integration tests 

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox