Removed obsolete routes.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8017 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
2507fd1cd4
commit
526736dedc
@ -92,10 +92,6 @@ ActionController::Routing::Routes.draw do |map|
|
|||||||
reports.connect 'projects/:id/issues/report/:detail', :action => 'issue_report_details'
|
reports.connect 'projects/:id/issues/report/:detail', :action => 'issue_report_details'
|
||||||
end
|
end
|
||||||
|
|
||||||
# Following two routes conflict with the resources because #index allows POST
|
|
||||||
map.connect '/issues', :controller => 'issues', :action => 'index', :conditions => { :method => :post }
|
|
||||||
map.connect '/issues/create', :controller => 'issues', :action => 'index', :conditions => { :method => :post }
|
|
||||||
|
|
||||||
map.resources :issues, :member => { :edit => :post }, :collection => {} do |issues|
|
map.resources :issues, :member => { :edit => :post }, :collection => {} do |issues|
|
||||||
issues.resources :time_entries, :controller => 'timelog'
|
issues.resources :time_entries, :controller => 'timelog'
|
||||||
issues.resources :relations, :shallow => true, :controller => 'issue_relations', :only => [:index, :show, :create, :destroy]
|
issues.resources :relations, :shallow => true, :controller => 'issue_relations', :only => [:index, :show, :create, :destroy]
|
||||||
|
@ -89,7 +89,7 @@ class IssuesTest < ActionController::IntegrationTest
|
|||||||
assert_equal 0, Issue.find(1).attachments.length
|
assert_equal 0, Issue.find(1).attachments.length
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_other_formats_links_on_get_index
|
def test_other_formats_links_on_index
|
||||||
get '/projects/ecookbook/issues'
|
get '/projects/ecookbook/issues'
|
||||||
|
|
||||||
%w(Atom PDF CSV).each do |format|
|
%w(Atom PDF CSV).each do |format|
|
||||||
@ -99,8 +99,8 @@ class IssuesTest < ActionController::IntegrationTest
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_other_formats_links_on_post_index_without_project_id_in_url
|
def test_other_formats_links_on_index_without_project_id_in_url
|
||||||
post '/issues', :project_id => 'ecookbook'
|
get '/issues', :project_id => 'ecookbook'
|
||||||
|
|
||||||
%w(Atom PDF CSV).each do |format|
|
%w(Atom PDF CSV).each do |format|
|
||||||
assert_tag :a, :content => format,
|
assert_tag :a, :content => format,
|
||||||
@ -109,7 +109,7 @@ class IssuesTest < ActionController::IntegrationTest
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_pagination_links_on_get_index
|
def test_pagination_links_on_index
|
||||||
Setting.per_page_options = '2'
|
Setting.per_page_options = '2'
|
||||||
get '/projects/ecookbook/issues'
|
get '/projects/ecookbook/issues'
|
||||||
|
|
||||||
@ -118,9 +118,9 @@ class IssuesTest < ActionController::IntegrationTest
|
|||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_pagination_links_on_post_index_without_project_id_in_url
|
def test_pagination_links_on_index_without_project_id_in_url
|
||||||
Setting.per_page_options = '2'
|
Setting.per_page_options = '2'
|
||||||
post '/issues', :project_id => 'ecookbook'
|
get '/issues', :project_id => 'ecookbook'
|
||||||
|
|
||||||
assert_tag :a, :content => '2',
|
assert_tag :a, :content => '2',
|
||||||
:attributes => { :href => '/projects/ecookbook/issues?page=2' }
|
:attributes => { :href => '/projects/ecookbook/issues?page=2' }
|
||||||
|
Loading…
x
Reference in New Issue
Block a user