diff options
author | Jamis Buck <jamis@37signals.com> | 2005-05-30 09:12:12 +0000 |
---|---|---|
committer | Jamis Buck <jamis@37signals.com> | 2005-05-30 09:12:12 +0000 |
commit | 6ce58318f5c1446c33599e3d0d19491618c684a6 (patch) | |
tree | 097e62102ce3f5907935c1b4354db96111a76640 /actionpack/test | |
parent | f8542a64b30bb6f67bcedf0c82de1291aab3c3d9 (diff) | |
download | rails-6ce58318f5c1446c33599e3d0d19491618c684a6.tar.gz rails-6ce58318f5c1446c33599e3d0d19491618c684a6.tar.bz2 rails-6ce58318f5c1446c33599e3d0d19491618c684a6.zip |
render(:inline) defaults to :layout => false
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1372 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/test')
-rw-r--r-- | actionpack/test/controller/new_render_test.rb | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/actionpack/test/controller/new_render_test.rb b/actionpack/test/controller/new_render_test.rb index fb23b9e02c..a51bd2a83e 100644 --- a/actionpack/test/controller/new_render_test.rb +++ b/actionpack/test/controller/new_render_test.rb @@ -90,6 +90,10 @@ class NewRenderTestController < ActionController::Base render :inline => "Hello: <%= params[:name] %>" end + def accessing_params_in_template_with_layout + render :inline => "Hello: <%= params[:name] %>", :layout => nil + end + def rescue_action(e) raise end private @@ -97,7 +101,9 @@ class NewRenderTestController < ActionController::Base case action_name when "layout_test", "rendering_without_layout", "rendering_nothing_on_layout", "render_text_hello_world", - "partial_only", "partial_only_with_layout" + "partial_only", "partial_only_with_layout", + "accessing_params_in_template", + "accessing_params_in_template_with_layout" "layouts/standard" when "builder_layout_test" "layouts/builder" @@ -237,4 +243,9 @@ class NewRenderTest < Test::Unit::TestCase get :accessing_params_in_template, :name => "David" assert_equal "Hello: David", @response.body end + + def test_accessing_params_in_template_with_layout + get :accessing_params_in_template_with_layout, :name => "David" + assert_equal "<html>Hello: David</html>", @response.body + end end |