Use should_route in routing tests.

git-svn-id: http://svn.redmine.org/redmine/trunk@13608 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2014-11-16 14:23:32 +00:00
parent d72e1f95ba
commit ecda1c7a4f
46 changed files with 539 additions and 1808 deletions

View File

@@ -17,16 +17,9 @@
require File.expand_path('../../../test_helper', __FILE__)
class RoutingCalendarsTest < ActionDispatch::IntegrationTest
class RoutingCalendarsTest < Redmine::RoutingTest
def test_calendars
assert_routing(
{ :method => 'get', :path => "/issues/calendar" },
{ :controller => 'calendars', :action => 'show' }
)
assert_routing(
{ :method => 'get', :path => "/projects/project-name/issues/calendar" },
{ :controller => 'calendars', :action => 'show',
:project_id => 'project-name' }
)
should_route 'GET /issues/calendar' => 'calendars#show'
should_route 'GET /projects/foo/issues/calendar' => 'calendars#show', :project_id => 'foo'
end
end