diff options
author | Lance Ivy <lance@cainlevy.net> | 2009-04-15 16:46:30 -0700 |
---|---|---|
committer | Pratik Naik <pratiknaik@gmail.com> | 2009-05-17 18:56:06 +0200 |
commit | 11bac700784efe232083f94e3d28d171957e667e (patch) | |
tree | 9e9fbda32a8602af8da770fe1840b9d987d9f4a6 /actionpack/test/template | |
parent | 53dda29f8b34073a4b135ee224c1d09c1f10de02 (diff) | |
download | rails-11bac700784efe232083f94e3d28d171957e667e.tar.gz rails-11bac700784efe232083f94e3d28d171957e667e.tar.bz2 rails-11bac700784efe232083f94e3d28d171957e667e.zip |
Ensure auto_link does not ignore multiple trailing punctuations [#2504 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
Diffstat (limited to 'actionpack/test/template')
-rw-r--r-- | actionpack/test/template/text_helper_test.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/actionpack/test/template/text_helper_test.rb b/actionpack/test/template/text_helper_test.rb index be7163888e..a780bfc606 100644 --- a/actionpack/test/template/text_helper_test.rb +++ b/actionpack/test/template/text_helper_test.rb @@ -401,6 +401,13 @@ class TextHelperTest < ActionView::TestCase auto_link("Welcome to my new blog at http://www.myblog.com/. Please e-mail me at me@email.com.", :link => :all, :html => { :class => "menu", :target => "_blank" }) end + + def test_auto_link_with_multiple_trailing_punctuations + url = "http://youtube.com" + url_result = generate_result(url) + assert_equal url_result, auto_link(url) + assert_equal "(link: #{url_result}).", auto_link("(link: #{url}).") + end def test_cycle_class value = Cycle.new("one", 2, "3") |