From 027cfc02b1685dbcbc5fbd5dcf81891e87c7d4b5 Mon Sep 17 00:00:00 2001 From: Mike Dalessio Date: Fri, 28 Nov 2025 14:47:00 -0500 Subject: [PATCH] Restore the ability to pass arguments to `bin/rails test` The app is not loaded by rails/commands if there are additional arguments to "rails test" --- bin/rails | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/bin/rails b/bin/rails index 8f0b2d8b3..2f5b30e53 100755 --- a/bin/rails +++ b/bin/rails @@ -8,4 +8,8 @@ require_relative "../config/boot" require "rails/commands" -Fizzy::Saas.append_test_paths if Fizzy.saas? && Rails.env.test? +if Fizzy.saas? && ENV["RAILS_ENV"] == "test" + # the app is not loaded by rails/commands if there are additional arguments to "rails test" + require APP_PATH + Fizzy::Saas.append_test_paths +end