From f443ae670de9ce9bcb8c00adde08405d2cfd70db Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Sat, 5 Sep 2015 10:59:28 -0700 Subject: Use ERB::Utils to percent encode `hfvalue` parts of mailto `hfvalue` parts should always be percent encoded, so lets do that! Revert "use path escaping for email addresses" This reverts commit 21ffef38a5dc5a6a21f7e841aecab5b51f4fd185. --- actionview/test/template/url_helper_test.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'actionview/test/template') diff --git a/actionview/test/template/url_helper_test.rb b/actionview/test/template/url_helper_test.rb index 2bd3098217..027b72b354 100644 --- a/actionview/test/template/url_helper_test.rb +++ b/actionview/test/template/url_helper_test.rb @@ -501,14 +501,14 @@ class UrlHelperTest < ActiveSupport::TestCase def test_mail_to_with_special_characters assert_dom_equal( - %(#!$%&'*+-/=?^_`{}|~@example.org), + %{#!$%&'*+-/=?^_`{}|~@example.org}, mail_to("#!$%&'*+-/=?^_`{}|~@example.org") ) end def test_mail_with_options assert_dom_equal( - %{My email}, + %{My email}, mail_to("me@example.com", "My email", cc: "ccaddress@example.com", bcc: "bccaddress@example.com", subject: "This is an example email", body: "This is the body of the message.", reply_to: "foo@bar.com") ) @@ -533,7 +533,7 @@ class UrlHelperTest < ActiveSupport::TestCase end def test_mail_to_with_block_and_options - assert_dom_equal %{Email me}, + assert_dom_equal %{Email me}, mail_to('me@example.com', cc: "ccaddress@example.com", class: "special") { content_tag(:span, 'Email me') } end -- cgit v1.2.3