diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2015-01-03 17:17:16 -0300 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2015-01-04 11:58:42 -0300 |
commit | d282125a18c1697a9b5bb775628a2db239142ac7 (patch) | |
tree | 417ae772b2eb01111dcbe6c83674f19bab9ba7ca /railties/test/application | |
parent | 2cc91c37bc2e32b7a04b2d782fb8f4a69a14503f (diff) | |
download | rails-d282125a18c1697a9b5bb775628a2db239142ac7.tar.gz rails-d282125a18c1697a9b5bb775628a2db239142ac7.tar.bz2 rails-d282125a18c1697a9b5bb775628a2db239142ac7.zip |
Remove deprecate `*_path` helpers in email views
Diffstat (limited to 'railties/test/application')
-rw-r--r-- | railties/test/application/initializers/frameworks_test.rb | 1 | ||||
-rw-r--r-- | railties/test/application/mailer_previews_test.rb | 52 |
2 files changed, 0 insertions, 53 deletions
diff --git a/railties/test/application/initializers/frameworks_test.rb b/railties/test/application/initializers/frameworks_test.rb index 2d45c9b53f..97b51911d9 100644 --- a/railties/test/application/initializers/frameworks_test.rb +++ b/railties/test/application/initializers/frameworks_test.rb @@ -65,7 +65,6 @@ module ApplicationTests RUBY require "#{app_path}/config/environment" - assert Foo.method_defined?(:foo_path) assert Foo.method_defined?(:foo_url) assert Foo.method_defined?(:main_app) end diff --git a/railties/test/application/mailer_previews_test.rb b/railties/test/application/mailer_previews_test.rb index 9e4f858539..1752a9f3c6 100644 --- a/railties/test/application/mailer_previews_test.rb +++ b/railties/test/application/mailer_previews_test.rb @@ -428,58 +428,6 @@ module ApplicationTests assert_match '<option selected value="?part=text%2Fplain">View as plain-text email</option>', last_response.body end - test "*_path helpers emit a deprecation" do - - app_file "config/routes.rb", <<-RUBY - Rails.application.routes.draw do - get 'foo', to: 'foo#index' - end - RUBY - - mailer 'notifier', <<-RUBY - class Notifier < ActionMailer::Base - default from: "from@example.com" - - def path_in_view - mail to: "to@example.org" - end - - def path_in_mailer - @url = foo_path - mail to: "to@example.org" - end - end - RUBY - - html_template 'notifier/path_in_view', "<%= link_to 'foo', foo_path %>" - - mailer_preview 'notifier', <<-RUBY - class NotifierPreview < ActionMailer::Preview - def path_in_view - Notifier.path_in_view - end - - def path_in_mailer - Notifier.path_in_mailer - end - end - RUBY - - app('development') - - assert_deprecated do - get "/rails/mailers/notifier/path_in_view.html" - assert_equal 200, last_response.status - end - - html_template 'notifier/path_in_mailer', "No ERB in here" - - assert_deprecated do - get "/rails/mailers/notifier/path_in_mailer.html" - assert_equal 200, last_response.status - end - end - private def build_app super |