From 9d39f81d512e0d16a27e2e864ea2dd0e8dc41b17 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafael=20Mendon=C3=A7a=20Fran=C3=A7a?= Date: Wed, 16 Jan 2019 20:45:32 -0500 Subject: [PATCH] Remove deprecated `capify!` --- railties/CHANGELOG.md | 4 ++++ railties/lib/rails/generators/actions.rb | 9 --------- railties/test/generators/actions_test.rb | 9 --------- 3 files changed, 4 insertions(+), 18 deletions(-) diff --git a/railties/CHANGELOG.md b/railties/CHANGELOG.md index ee51a94754..2df46fe9d5 100644 --- a/railties/CHANGELOG.md +++ b/railties/CHANGELOG.md @@ -1,3 +1,7 @@ +* Remove deprecated `capify!`. + + *Rafael Mendonça França* + * Remove deprecated `config.secret_token`. *Rafael Mendonça França* diff --git a/railties/lib/rails/generators/actions.rb b/railties/lib/rails/generators/actions.rb index 4646a55316..5b056045b3 100644 --- a/railties/lib/rails/generators/actions.rb +++ b/railties/lib/rails/generators/actions.rb @@ -248,15 +248,6 @@ module Rails execute_command :rails, command, options end - # Just run the capify command in root - # - # capify! - def capify! - ActiveSupport::Deprecation.warn("`capify!` is deprecated and will be removed in the next version of Rails.") - log :capify, "" - in_root { run("#{extify(:capify)} .", verbose: false) } - end - # Make an entry in Rails routing file config/routes.rb # # route "root 'welcome#index'" diff --git a/railties/test/generators/actions_test.rb b/railties/test/generators/actions_test.rb index af475400a1..4932100ea2 100644 --- a/railties/test/generators/actions_test.rb +++ b/railties/test/generators/actions_test.rb @@ -412,15 +412,6 @@ class ActionsTest < Rails::Generators::TestCase end end - def test_capify_should_run_the_capify_command - content = capture(:stderr) do - assert_called_with(generator, :run, ["capify .", verbose: false]) do - action :capify! - end - end - assert_match(/DEPRECATION WARNING: `capify!` is deprecated/, content) - end - def test_route_should_add_data_to_the_routes_block_in_config_routes run_generator route_command = "route '/login', controller: 'sessions', action: 'new'"