##// END OF EJS Templates
Rails4: replace deprecated Relation#sum with finder options at lib/redmine/helpers/time_report.rb...
Rails4: replace deprecated Relation#sum with finder options at lib/redmine/helpers/time_report.rb git-svn-id: http://svn.redmine.org/redmine/trunk@12881 e93f8b46-1217-0410-a6f0-8f06a7374b81

File last commit:

r12461:35cc911192e0
r12606:0aaf7f799aba
Show More
watchers_test.rb
61 lines | 2.4 KiB | text/x-ruby | RubyLexer
Toshi MARUYAMA
test: route: add watchers test defined at r8162...
r8274 # Redmine - project management software
Toshi MARUYAMA
update copyright year (#15977)...
r12461 # Copyright (C) 2006-2014 Jean-Philippe Lang
Toshi MARUYAMA
test: route: add watchers test defined at r8162...
r8274 #
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
require File.expand_path('../../../test_helper', __FILE__)
class RoutingWatchersTest < ActionController::IntegrationTest
def test_watchers
Jean-Philippe Lang
Ability to add non-member users as watchers (#5159)....
r8472 assert_routing(
{ :method => 'get', :path => "/watchers/new" },
{ :controller => 'watchers', :action => 'new' }
)
Jean-Philippe Lang
Ability to add non-member watchers on issue creation (#5159)....
r9134 assert_routing(
{ :method => 'post', :path => "/watchers/append" },
{ :controller => 'watchers', :action => 'append' }
)
Jean-Philippe Lang
Ability to add non-member users as watchers (#5159)....
r8472 assert_routing(
{ :method => 'post', :path => "/watchers" },
{ :controller => 'watchers', :action => 'create' }
)
Toshi MARUYAMA
test: route: add watchers test defined at r8162...
r8274 assert_routing(
Jean-Philippe Lang
Fixed that delete watcher link was broken by r11290 (#13231)....
r11213 { :method => 'delete', :path => "/watchers" },
Toshi MARUYAMA
test: route: add watchers test defined at r8162...
r8274 { :controller => 'watchers', :action => 'destroy' }
)
Jean-Philippe Lang
Ability to add non-member users as watchers (#5159)....
r8472 assert_routing(
{ :method => 'get', :path => "/watchers/autocomplete_for_user" },
{ :controller => 'watchers', :action => 'autocomplete_for_user' }
)
Toshi MARUYAMA
test: route: add watchers test defined at r8162...
r8274 assert_routing(
{ :method => 'post', :path => "/watchers/watch" },
{ :controller => 'watchers', :action => 'watch' }
)
assert_routing(
Jean-Philippe Lang
Use POST/DELETE to watch/unwatch an item....
r11113 { :method => 'delete', :path => "/watchers/watch" },
Toshi MARUYAMA
test: route: add watchers test defined at r8162...
r8274 { :controller => 'watchers', :action => 'unwatch' }
)
Jean-Philippe Lang
Add/remove issue watchers via the REST API (#6727)....
r11060 assert_routing(
{ :method => 'post', :path => "/issues/12/watchers.xml" },
{ :controller => 'watchers', :action => 'create',
:object_type => 'issue', :object_id => '12', :format => 'xml' }
)
assert_routing(
{ :method => 'delete', :path => "/issues/12/watchers/3.xml" },
{ :controller => 'watchers', :action => 'destroy',
:object_type => 'issue', :object_id => '12', :user_id => '3', :format => 'xml'}
)
Toshi MARUYAMA
test: route: add watchers test defined at r8162...
r8274 end
end