diff options
author | Joshua Peek <josh@joshpeek.com> | 2009-12-11 12:46:50 -0600 |
---|---|---|
committer | Joshua Peek <josh@joshpeek.com> | 2009-12-11 12:46:50 -0600 |
commit | 2297eaed5b195ea42b99d062ad45f87dde9d3c60 (patch) | |
tree | 67b90f1e13a88d60170469e281f081711a976194 /actionpack/test/dispatch | |
parent | 61e9f2023baead046c7f8ba7c89a7496bf49d1be (diff) | |
download | rails-2297eaed5b195ea42b99d062ad45f87dde9d3c60.tar.gz rails-2297eaed5b195ea42b99d062ad45f87dde9d3c60.tar.bz2 rails-2297eaed5b195ea42b99d062ad45f87dde9d3c60.zip |
"new" and "edit" name routes always need to be prepend to the
named_route [#3561 state:resolved]
Diffstat (limited to 'actionpack/test/dispatch')
-rw-r--r-- | actionpack/test/dispatch/routing_test.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/actionpack/test/dispatch/routing_test.rb b/actionpack/test/dispatch/routing_test.rb index 22ef48b668..425796b460 100644 --- a/actionpack/test/dispatch/routing_test.rb +++ b/actionpack/test/dispatch/routing_test.rb @@ -228,9 +228,23 @@ class TestRoutingMapper < ActionDispatch::IntegrationTest assert_equal 'involvements#index', @response.body assert_equal '/projects/1/involvements', project_involvements_path(:project_id => '1') + get '/projects/1/involvements/new' + assert_equal 'involvements#new', @response.body + assert_equal '/projects/1/involvements/new', new_project_involvement_path(:project_id => '1') + get '/projects/1/involvements/1' assert_equal 'involvements#show', @response.body assert_equal '/projects/1/involvements/1', project_involvement_path(:project_id => '1', :id => '1') + + put '/projects/1/involvements/1' + assert_equal 'involvements#update', @response.body + + delete '/projects/1/involvements/1' + assert_equal 'involvements#destroy', @response.body + + get '/projects/1/involvements/1/edit' + assert_equal 'involvements#edit', @response.body + assert_equal '/projects/1/involvements/1/edit', edit_project_involvement_path(:project_id => '1', :id => '1') end end |