Changeset 1372
- Timestamp:
- 05/30/05 09:12:12 (3 years ago)
- Files:
-
- trunk/actionpack/CHANGELOG (modified) (1 diff)
- trunk/actionpack/lib/action_controller/layout.rb (modified) (1 diff)
- trunk/actionpack/test/controller/new_render_test.rb (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/actionpack/CHANGELOG
r1371 r1372 1 1 *SVN* 2 3 * render(:inline) always defaults to :layout => false. 2 4 3 5 * Make sure the benchmarking render method always returns the output of the render. trunk/actionpack/lib/action_controller/layout.rb
r1369 r1372 222 222 return options unless options.is_a?(Hash) 223 223 case 224 when options[:text], options[:partial], options[:nothing] 225 # by default, :text, :partial, and :nothing never use a layout224 when options[:text], options[:partial], options[:nothing], options[:inline] 225 # by default, :text, :partial, :inline, and :nothing never use a layout 226 226 { :layout => false }.merge(options) 227 227 else trunk/actionpack/test/controller/new_render_test.rb
r1371 r1372 89 89 def accessing_params_in_template 90 90 render :inline => "Hello: <%= params[:name] %>" 91 end 92 93 def accessing_params_in_template_with_layout 94 render :inline => "Hello: <%= params[:name] %>", :layout => nil 91 95 end 92 96 … … 98 102 when "layout_test", "rendering_without_layout", 99 103 "rendering_nothing_on_layout", "render_text_hello_world", 100 "partial_only", "partial_only_with_layout" 104 "partial_only", "partial_only_with_layout", 105 "accessing_params_in_template", 106 "accessing_params_in_template_with_layout" 101 107 "layouts/standard" 102 108 when "builder_layout_test" … … 238 244 assert_equal "Hello: David", @response.body 239 245 end 246 247 def test_accessing_params_in_template_with_layout 248 get :accessing_params_in_template_with_layout, :name => "David" 249 assert_equal "<html>Hello: David</html>", @response.body 250 end 240 251 end