diff options
author | Xavier Noria <fxn@hashref.com> | 2010-07-30 02:35:24 +0200 |
---|---|---|
committer | Xavier Noria <fxn@hashref.com> | 2010-07-30 02:35:24 +0200 |
commit | ccd45618ed9a629c9535a5ff84ef5c238befa4ab (patch) | |
tree | 0a582bf695dce01240762d2b8516efde43bc3515 /actionpack/test | |
parent | 3c3ff1377d17b584dd14d85c7cecab59ddff2679 (diff) | |
parent | 755af497555fde16db86f7e51f6462b0aca79b49 (diff) | |
download | rails-ccd45618ed9a629c9535a5ff84ef5c238befa4ab.tar.gz rails-ccd45618ed9a629c9535a5ff84ef5c238befa4ab.tar.bz2 rails-ccd45618ed9a629c9535a5ff84ef5c238befa4ab.zip |
Merge remote branch 'rails/master'
Diffstat (limited to 'actionpack/test')
-rw-r--r-- | actionpack/test/template/javascript_helper_test.rb | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/actionpack/test/template/javascript_helper_test.rb b/actionpack/test/template/javascript_helper_test.rb index 1a899c6aee..a8ca19931b 100644 --- a/actionpack/test/template/javascript_helper_test.rb +++ b/actionpack/test/template/javascript_helper_test.rb @@ -90,11 +90,12 @@ class JavaScriptHelperTest < ActionView::TestCase end def test_link_to_function_with_inner_block_does_not_raise_exception - html = link_to_function("Greet me!") do |page| - content_tag(:h1) { 'Hi' } + html = link_to_function( "Greet me!" ) do |page| + page.replace_html 'header', (content_tag :h1 do + 'Greetings' + end) end - - assert_dom_equal %(<a href='#' onclick="; return false;">Greet me!</a>), html + assert_dom_equal %(<a href="#" onclick="Element.update("header", "\\u003Ch1\\u003EGreetings\\u003C/h1\\u003E");; return false;">Greet me!</a>), html end def test_javascript_tag |