aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/controller/new_base/render_implicit_action_test.rb
diff options
context:
space:
mode:
authorSantiago Pastorino <santiago@wyeworks.com>2011-04-02 23:45:07 -0300
committerSantiago Pastorino <santiago@wyeworks.com>2011-04-02 23:47:50 -0300
commitcc58fe79ac6f4d5fd54a39ff6e7f087c6a04fee8 (patch)
tree3316760e48494d875b8d957ea08a0b12f313f71d /actionpack/test/controller/new_base/render_implicit_action_test.rb
parent99da42c29944beed0cb9e892ae90bfeb2590c57e (diff)
downloadrails-cc58fe79ac6f4d5fd54a39ff6e7f087c6a04fee8.tar.gz
rails-cc58fe79ac6f4d5fd54a39ff6e7f087c6a04fee8.tar.bz2
rails-cc58fe79ac6f4d5fd54a39ff6e7f087c6a04fee8.zip
Implicit actions named not_implemented can be rendered
Diffstat (limited to 'actionpack/test/controller/new_base/render_implicit_action_test.rb')
-rw-r--r--actionpack/test/controller/new_base/render_implicit_action_test.rb13
1 files changed, 11 insertions, 2 deletions
diff --git a/actionpack/test/controller/new_base/render_implicit_action_test.rb b/actionpack/test/controller/new_base/render_implicit_action_test.rb
index 667a9021be..3bb3016fdb 100644
--- a/actionpack/test/controller/new_base/render_implicit_action_test.rb
+++ b/actionpack/test/controller/new_base/render_implicit_action_test.rb
@@ -3,8 +3,9 @@ require 'abstract_unit'
module RenderImplicitAction
class SimpleController < ::ApplicationController
self.view_paths = [ActionView::FixtureResolver.new(
- "render_implicit_action/simple/hello_world.html.erb" => "Hello world!",
- "render_implicit_action/simple/hyphen-ated.html.erb" => "Hello hyphen-ated!"
+ "render_implicit_action/simple/hello_world.html.erb" => "Hello world!",
+ "render_implicit_action/simple/hyphen-ated.html.erb" => "Hello hyphen-ated!",
+ "render_implicit_action/simple/not_implemented.html.erb" => "Not Implemented"
)]
def hello_world() end
@@ -25,9 +26,17 @@ module RenderImplicitAction
assert_status 200
end
+ test "render an action called not_implemented" do
+ get "/render_implicit_action/simple/not_implemented"
+
+ assert_body "Not Implemented"
+ assert_status 200
+ end
+
test "action_method? returns true for implicit actions" do
assert SimpleController.new.action_method?(:hello_world)
assert SimpleController.new.action_method?(:"hyphen-ated")
+ assert SimpleController.new.action_method?(:not_implemented)
end
end
end