aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/template/url_helper_test.rb
diff options
context:
space:
mode:
authorrick <technoweenie@gmail.com>2008-06-19 09:59:36 -0700
committerrick <technoweenie@gmail.com>2008-06-19 09:59:36 -0700
commit10c581a6deed66e8b62de6e7a3621a63de90baad (patch)
tree588ceb1118761602caa8ccf248dd08d59f33896c /actionpack/test/template/url_helper_test.rb
parent64637da284ed4685591c178202ee103e6bee71cf (diff)
parent81025b5808886289f54d698f73f4199c99223e7e (diff)
downloadrails-10c581a6deed66e8b62de6e7a3621a63de90baad.tar.gz
rails-10c581a6deed66e8b62de6e7a3621a63de90baad.tar.bz2
rails-10c581a6deed66e8b62de6e7a3621a63de90baad.zip
fix merge
Diffstat (limited to 'actionpack/test/template/url_helper_test.rb')
-rw-r--r--actionpack/test/template/url_helper_test.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/actionpack/test/template/url_helper_test.rb b/actionpack/test/template/url_helper_test.rb
index d45ea08a6f..0713cea8ac 100644
--- a/actionpack/test/template/url_helper_test.rb
+++ b/actionpack/test/template/url_helper_test.rb
@@ -211,6 +211,14 @@ class UrlHelperTest < ActionView::TestCase
def test_link_tag_using_post_javascript_and_popup
assert_raises(ActionView::ActionViewError) { link_to("Hello", "http://www.example.com", :popup => true, :method => :post, :confirm => "Are you serious?") }
end
+
+ def test_link_tag_using_block
+ self.output_buffer = ''
+
+ link_to("http://example.com") { concat("Example site") }
+
+ assert_equal '<a href="http://example.com">Example site</a>', output_buffer
+ end
def test_link_to_unless
assert_equal "Showing", link_to_unless(true, "Showing", :action => "show", :controller => "weblog")