diff options
Diffstat (limited to 'actionpack/test/template/capture_helper_test.rb')
-rw-r--r-- | actionpack/test/template/capture_helper_test.rb | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/actionpack/test/template/capture_helper_test.rb b/actionpack/test/template/capture_helper_test.rb index 25da17bde9..03050485fa 100644 --- a/actionpack/test/template/capture_helper_test.rb +++ b/actionpack/test/template/capture_helper_test.rb @@ -29,8 +29,13 @@ class CaptureHelperTest < ActionView::TestCase end def test_capture_escapes_html - string = @av.capture { '<strong>foo</strong><em>bar</em>' } - assert_equal '<strong>foo</strong><em>bar</em>', string + string = @av.capture { '<em>bar</em>' } + assert_equal '<em>bar</em>', string + end + + def test_capture_doesnt_escape_twice + string = @av.capture { '<em>bar</em>'.html_safe } + assert_equal '<em>bar</em>', string end def test_content_for |