diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2012-07-24 12:24:01 -0700 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2012-07-24 12:24:01 -0700 |
commit | d7856d3fad5cf61beaca997b9757b181c4821b86 (patch) | |
tree | 2ddf0baccc8439fd639014dfcf5409f1fe768c28 /actionpack/test | |
parent | 66b859bd9e7138b27902805721309ce03b722de3 (diff) | |
parent | 9a020bd8f924895c5e064b913df383b8ed77ac2a (diff) | |
download | rails-d7856d3fad5cf61beaca997b9757b181c4821b86.tar.gz rails-d7856d3fad5cf61beaca997b9757b181c4821b86.tar.bz2 rails-d7856d3fad5cf61beaca997b9757b181c4821b86.zip |
Merge pull request #7150 from lucasmazza/flush_option
Replace the flush parameter with a Hash.
Diffstat (limited to 'actionpack/test')
-rw-r--r-- | actionpack/test/template/capture_helper_test.rb | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/actionpack/test/template/capture_helper_test.rb b/actionpack/test/template/capture_helper_test.rb index 17469f8c3e..234ac3252d 100644 --- a/actionpack/test/template/capture_helper_test.rb +++ b/actionpack/test/template/capture_helper_test.rb @@ -56,7 +56,7 @@ class CaptureHelperTest < ActionView::TestCase def test_content_for_with_multiple_calls_and_flush assert ! content_for?(:title) content_for :title, 'foo' - content_for :title, 'bar', true + content_for :title, 'bar', flush: true assert_equal 'bar', content_for(:title) end @@ -75,7 +75,7 @@ class CaptureHelperTest < ActionView::TestCase content_for :title do 'foo' end - content_for :title, true do + content_for :title, flush: true do 'bar' end assert_equal 'bar', content_for(:title) @@ -86,7 +86,7 @@ class CaptureHelperTest < ActionView::TestCase content_for :title do 'foo' end - content_for :title, nil, true do + content_for :title, nil, flush: true do 'bar' end assert_equal 'bar', content_for(:title) @@ -97,7 +97,7 @@ class CaptureHelperTest < ActionView::TestCase content_for :title do 'foo' end - content_for :title, false do + content_for :title, flush: false do 'bar' end assert_equal 'foobar', content_for(:title) @@ -117,11 +117,11 @@ class CaptureHelperTest < ActionView::TestCase def test_content_for_with_whitespace_block_and_flush assert ! content_for?(:title) content_for :title, 'foo' - content_for :title, true do + content_for :title, flush: true do output_buffer << " \n " nil end - content_for :title, 'bar', true + content_for :title, 'bar', flush: true assert_equal 'bar', content_for(:title) end @@ -131,9 +131,9 @@ class CaptureHelperTest < ActionView::TestCase assert_equal nil, content_for(:title) { output_buffer << 'bar'; nil } assert_equal nil, content_for(:title) { output_buffer << " \n "; nil } assert_equal 'foobar', content_for(:title) - assert_equal nil, content_for(:title, 'foo', true) - assert_equal nil, content_for(:title, true) { output_buffer << 'bar'; nil } - assert_equal nil, content_for(:title, true) { output_buffer << " \n "; nil } + assert_equal nil, content_for(:title, 'foo', flush: true) + assert_equal nil, content_for(:title, flush: true) { output_buffer << 'bar'; nil } + assert_equal nil, content_for(:title, flush: true) { output_buffer << " \n "; nil } assert_equal 'bar', content_for(:title) end |