diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2006-09-04 05:51:48 +0000 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2006-09-04 05:51:48 +0000 |
commit | da8d7a7011b1d6e1bd9a5c757aa4514d4612c100 (patch) | |
tree | b1dcd1e2d11151eafb1df81429c879b480baa704 /actionpack | |
parent | e04a6e81555dbc72a211b2416982a2c69e7d6dcc (diff) | |
download | rails-da8d7a7011b1d6e1bd9a5c757aa4514d4612c100.tar.gz rails-da8d7a7011b1d6e1bd9a5c757aa4514d4612c100.tar.bz2 rails-da8d7a7011b1d6e1bd9a5c757aa4514d4612c100.zip |
deprecated render assertions
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4977 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack')
-rw-r--r-- | actionpack/test/controller/render_test.rb | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/actionpack/test/controller/render_test.rb b/actionpack/test/controller/render_test.rb index acdd8d9984..c22702acd0 100644 --- a/actionpack/test/controller/render_test.rb +++ b/actionpack/test/controller/render_test.rb @@ -127,7 +127,7 @@ class RenderTest < Test::Unit::TestCase end def test_do_with_render - get :render_hello_world + assert_deprecated_render { get :render_hello_world } assert_template "test/hello_world" end @@ -184,7 +184,7 @@ class RenderTest < Test::Unit::TestCase end def test_render_xml - get :render_xml_hello + assert_deprecated_render { get :render_xml_hello } assert_equal "<html>\n <p>Hello David</p>\n<p>This is grand!</p>\n</html>\n", @response.body end @@ -243,4 +243,9 @@ class RenderTest < Test::Unit::TestCase get :accessing_local_assigns_in_inline_template_with_string_keys, :local_name => "Local David" assert_equal "Goodbye, Local David", @response.body end + + protected + def assert_deprecated_render(&block) + assert_deprecated(/render/, &block) + end end |