Permalink
Browse files

Merge pull request #31610 from prathamesh-sonpatki/improve-deprecatio…

…n-msg-pr-29358

Improve the deprecation message for using subclass of Rails::Application to start the Rails server
  • Loading branch information...
eileencodes committed Jan 7, 2018
2 parents f614c5f + b821f95 commit 3b57bf22739e4954ec2edc86775f4ee77d6226bc
View
@@ -57,7 +57,7 @@
*bogdanvlviv*
* Deprecate support of use `Rails::Application` subclass to start Rails server.
* Deprecate support for using a `Rails::Application` subclass to start Rails server.
*Yuji Yaginuma*
@@ -27,7 +27,7 @@ def app
app = super
if app.is_a?(Class)
ActiveSupport::Deprecation.warn(<<-MSG.squish)
Use `Rails::Application` subclass to start the server is deprecated and will be removed in Rails 6.0.
Using `Rails::Application` subclass to start the server is deprecated and will be removed in Rails 6.0.
Please change `run #{app}` to `run Rails.application` in config.ru.
MSG
end
@@ -29,7 +29,7 @@ def teardown
server.app
log = File.read(Rails.application.config.paths["log"].first)
assert_match(/DEPRECATION WARNING: Use `Rails::Application` subclass to start the server is deprecated/, log)
assert_match(/DEPRECATION WARNING: Using `Rails::Application` subclass to start the server is deprecated/, log)
end
test "restart rails server with custom pid file path" do

0 comments on commit 3b57bf2

Please sign in to comment.