aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/controller
diff options
context:
space:
mode:
authorCarlos Antonio da Silva <carlosantoniodasilva@gmail.com>2012-05-03 23:26:54 -0300
committerCarlos Antonio da Silva <carlosantoniodasilva@gmail.com>2012-05-04 15:17:04 -0300
commitd03aa104e069be4e301efa8cefb90a2a785a7bff (patch)
tree105d468d8067e80eedfe4fc796fb5730bf5d9b13 /actionpack/test/controller
parent319db7b189fe1f02268c99c9e9566312535c02ec (diff)
downloadrails-d03aa104e069be4e301efa8cefb90a2a785a7bff.tar.gz
rails-d03aa104e069be4e301efa8cefb90a2a785a7bff.tar.bz2
rails-d03aa104e069be4e301efa8cefb90a2a785a7bff.zip
Force given path to http methods in mapper to skip canonical action checking
This fixes the following scenario: resources :contacts do post 'new', action: 'new', on: :collection, as: :new end Where the /new path is not generated because it's considered a canonical action, part of the normal resource actions: new_contacts POST /contacts(.:format) contacts#new Fixes #2999
Diffstat (limited to 'actionpack/test/controller')
-rw-r--r--actionpack/test/controller/routing_test.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/actionpack/test/controller/routing_test.rb b/actionpack/test/controller/routing_test.rb
index bcb4e6a766..cd91064ab8 100644
--- a/actionpack/test/controller/routing_test.rb
+++ b/actionpack/test/controller/routing_test.rb
@@ -1405,7 +1405,7 @@ class RouteSetTest < ActiveSupport::TestCase
end
end
end
-
+
def test_route_with_subdomain_and_constraints_must_receive_params
name_param = nil
set.draw do
@@ -1418,7 +1418,7 @@ class RouteSetTest < ActiveSupport::TestCase
set.recognize_path('http://subdomain.example.org/page/mypage'))
assert_equal(name_param, 'mypage')
end
-
+
def test_route_requirement_recognize_with_ignore_case
set.draw do
get 'page/:name' => 'pages#show',