diff options
Diffstat (limited to 'actionpack/test/new_base/render_layout_test.rb')
-rw-r--r-- | actionpack/test/new_base/render_layout_test.rb | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/actionpack/test/new_base/render_layout_test.rb b/actionpack/test/new_base/render_layout_test.rb index 5d28926cc6..7f627f86ec 100644 --- a/actionpack/test/new_base/render_layout_test.rb +++ b/actionpack/test/new_base/render_layout_test.rb @@ -6,7 +6,8 @@ module ControllerLayouts self.view_paths = [ActionView::Template::FixturePath.new( "layouts/application.html.erb" => "OMG <%= yield %> KTHXBAI", "layouts/override.html.erb" => "Override! <%= yield %>", - "basic.html.erb" => "Hello world!" + "basic.html.erb" => "Hello world!", + "controller_layouts/implicit/layout_false.html.erb" => "hai(layout_false.html.erb)" )] def index @@ -17,6 +18,12 @@ module ControllerLayouts render :template => "basic", :layout => "override" end + def layout_false + render :layout => false + end + + + def builder_override end @@ -56,4 +63,13 @@ module ControllerLayouts get "/controller_layouts/implicit/override" assert_body "Override! Hello world!" end + + class TestLayoutOptions < SimpleRouteCase + testing ControllerLayouts::ImplicitController + + test "rendering with :layout => false leaves out the implicit layout" do + get :layout_false + assert_response "hai(layout_false.html.erb)" + end + end end
\ No newline at end of file |