From f35f47b8c0bbb181352e9c957f02693cb1801b76 Mon Sep 17 00:00:00 2001 From: Yehuda Katz + Carl Lerche Date: Tue, 9 Jun 2009 16:46:42 -0700 Subject: Cleaning up and documenting AbstractController::Layouts --- actionpack/test/abstract_controller/abstract_controller_test.rb | 2 +- actionpack/test/abstract_controller/layouts_test.rb | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'actionpack/test/abstract_controller') diff --git a/actionpack/test/abstract_controller/abstract_controller_test.rb b/actionpack/test/abstract_controller/abstract_controller_test.rb index c7eaaeb4ba..05b55216c8 100644 --- a/actionpack/test/abstract_controller/abstract_controller_test.rb +++ b/actionpack/test/abstract_controller/abstract_controller_test.rb @@ -154,7 +154,7 @@ module AbstractController end def render_to_body(options = {}) - options[:_layout] = options[:layout] || _default_layout + options[:_layout] = options[:layout] || _default_layout({}) super end end diff --git a/actionpack/test/abstract_controller/layouts_test.rb b/actionpack/test/abstract_controller/layouts_test.rb index 4b66f063f3..64c435abb7 100644 --- a/actionpack/test/abstract_controller/layouts_test.rb +++ b/actionpack/test/abstract_controller/layouts_test.rb @@ -25,7 +25,7 @@ module AbstractControllerTests def controller_path() self.class.controller_path end def render_to_body(options) - options[:_layout] = _default_layout + options[:_layout] = _default_layout({}) super end end @@ -221,11 +221,11 @@ module AbstractControllerTests test "raises an exception when specifying layout true" do assert_raises ArgumentError do - Object.class_eval <<-RUBY_EVAL, __FILE__, __LINE__ + 1 + Object.class_eval do class ::BadOmgFailLolLayout < AbstractControllerTests::Layouts::Base layout true end - RUBY_EVAL + end end end end -- cgit v1.2.3