aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test
diff options
context:
space:
mode:
authorAaron Patterson <aaron.patterson@gmail.com>2012-02-29 12:03:15 -0800
committerAaron Patterson <aaron.patterson@gmail.com>2012-02-29 12:03:15 -0800
commitf9995ce0e03444e31d710a06e054365e33fee0d2 (patch)
treedaa30dacb75d70d7b476706328566dc18ce713e6 /actionpack/test
parent1d215286c9019a0fa98e87bffccc8fc2b97d5a46 (diff)
parentb27c29ef4a26755b8de04686241694ce5ee33724 (diff)
downloadrails-f9995ce0e03444e31d710a06e054365e33fee0d2.tar.gz
rails-f9995ce0e03444e31d710a06e054365e33fee0d2.tar.bz2
rails-f9995ce0e03444e31d710a06e054365e33fee0d2.zip
Merge pull request #5203 from avakhov/anonymous-controller-layout
Fix layout lookup for anonymous controller
Diffstat (limited to 'actionpack/test')
-rw-r--r--actionpack/test/abstract/layouts_test.rb12
1 files changed, 12 insertions, 0 deletions
diff --git a/actionpack/test/abstract/layouts_test.rb b/actionpack/test/abstract/layouts_test.rb
index fc25718d9e..e07a6de4a9 100644
--- a/actionpack/test/abstract/layouts_test.rb
+++ b/actionpack/test/abstract/layouts_test.rb
@@ -299,6 +299,18 @@ module AbstractControllerTests
controller.process(:index)
assert_equal "Overwrite Hello index!", controller.response_body
end
+
+ test "layout for anonymous controller" do
+ klass = Class.new(WithString) do
+ def index
+ render :text => 'index', :layout => true
+ end
+ end
+
+ controller = klass.new
+ controller.process(:index)
+ assert_equal "With String index", controller.response_body
+ end
end
end
end