Isolates all API routing tests to a specific test case.

git-svn-id: http://svn.redmine.org/redmine/trunk@13604 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2014-11-16 10:54:33 +00:00
parent cd6b2f2268
commit eae9c9ab2b
22 changed files with 207 additions and 438 deletions

View File

@@ -27,10 +27,6 @@ class RoutingProjectsTest < ActionDispatch::IntegrationTest
{ :method => 'get', :path => "/projects.atom" },
{ :controller => 'projects', :action => 'index', :format => 'atom' }
)
assert_routing(
{ :method => 'get', :path => "/projects.xml" },
{ :controller => 'projects', :action => 'index', :format => 'xml' }
)
assert_routing(
{ :method => 'get', :path => "/projects/new" },
{ :controller => 'projects', :action => 'new' }
@@ -39,11 +35,6 @@ class RoutingProjectsTest < ActionDispatch::IntegrationTest
{ :method => 'get', :path => "/projects/test" },
{ :controller => 'projects', :action => 'show', :id => 'test' }
)
assert_routing(
{ :method => 'get', :path => "/projects/1.xml" },
{ :controller => 'projects', :action => 'show', :id => '1',
:format => 'xml' }
)
assert_routing(
{ :method => 'get', :path => "/projects/4223/settings" },
{ :controller => 'projects', :action => 'settings', :id => '4223' }
@@ -57,10 +48,6 @@ class RoutingProjectsTest < ActionDispatch::IntegrationTest
{ :method => 'post', :path => "/projects" },
{ :controller => 'projects', :action => 'create' }
)
assert_routing(
{ :method => 'post', :path => "/projects.xml" },
{ :controller => 'projects', :action => 'create', :format => 'xml' }
)
assert_routing(
{ :method => 'post', :path => "/projects/64/archive" },
{ :controller => 'projects', :action => 'archive', :id => '64' }
@@ -81,19 +68,9 @@ class RoutingProjectsTest < ActionDispatch::IntegrationTest
{ :method => 'put', :path => "/projects/4223" },
{ :controller => 'projects', :action => 'update', :id => '4223' }
)
assert_routing(
{ :method => 'put', :path => "/projects/1.xml" },
{ :controller => 'projects', :action => 'update', :id => '1',
:format => 'xml' }
)
assert_routing(
{ :method => 'delete', :path => "/projects/64" },
{ :controller => 'projects', :action => 'destroy', :id => '64' }
)
assert_routing(
{ :method => 'delete', :path => "/projects/1.xml" },
{ :controller => 'projects', :action => 'destroy', :id => '1',
:format => 'xml' }
)
end
end