From 11bac700784efe232083f94e3d28d171957e667e Mon Sep 17 00:00:00 2001 From: Lance Ivy Date: Wed, 15 Apr 2009 16:46:30 -0700 Subject: Ensure auto_link does not ignore multiple trailing punctuations [#2504 state:resolved] Signed-off-by: Pratik Naik --- actionpack/test/template/text_helper_test.rb | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'actionpack/test') 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") -- cgit v1.2.3