Mercurial > hg > soundsoftware-site
comparison test/functional/versions_controller_test.rb @ 442:753f1380d6bc cannam
Merge from branch "redmine-1.2"
author | Chris Cannam |
---|---|
date | Mon, 06 Jun 2011 14:41:04 +0100 |
parents | cbce1fd3b1b7 |
children | cbb26bc654de |
comparison
equal
deleted
inserted
replaced
252:adc8466df404 | 442:753f1380d6bc |
---|---|
1 # redMine - project management software | 1 # Redmine - project management software |
2 # Copyright (C) 2006-2007 Jean-Philippe Lang | 2 # Copyright (C) 2006-2011 Jean-Philippe Lang |
3 # | 3 # |
4 # This program is free software; you can redistribute it and/or | 4 # This program is free software; you can redistribute it and/or |
5 # modify it under the terms of the GNU General Public License | 5 # modify it under the terms of the GNU General Public License |
6 # as published by the Free Software Foundation; either version 2 | 6 # as published by the Free Software Foundation; either version 2 |
7 # of the License, or (at your option) any later version. | 7 # of the License, or (at your option) any later version. |
20 | 20 |
21 # Re-raise errors caught by the controller. | 21 # Re-raise errors caught by the controller. |
22 class VersionsController; def rescue_action(e) raise e end; end | 22 class VersionsController; def rescue_action(e) raise e end; end |
23 | 23 |
24 class VersionsControllerTest < ActionController::TestCase | 24 class VersionsControllerTest < ActionController::TestCase |
25 fixtures :projects, :versions, :issues, :users, :roles, :members, :member_roles, :enabled_modules | 25 fixtures :projects, :versions, :issues, :users, :roles, :members, :member_roles, :enabled_modules, :issue_statuses |
26 | 26 |
27 def setup | 27 def setup |
28 @controller = VersionsController.new | 28 @controller = VersionsController.new |
29 @request = ActionController::TestRequest.new | 29 @request = ActionController::TestRequest.new |
30 @response = ActionController::TestResponse.new | 30 @response = ActionController::TestResponse.new |
143 def test_issue_status_by | 143 def test_issue_status_by |
144 xhr :get, :status_by, :id => 2 | 144 xhr :get, :status_by, :id => 2 |
145 assert_response :success | 145 assert_response :success |
146 assert_template '_issue_counts' | 146 assert_template '_issue_counts' |
147 end | 147 end |
148 | |
149 def test_issue_status_by_status | |
150 xhr :get, :status_by, :id => 2, :status_by => 'status' | |
151 assert_response :success | |
152 assert_template '_issue_counts' | |
153 end | |
148 end | 154 end |