diff options
author | Eric Davis <edavis@littlestreamsoftware.com> | 2010-02-12 19:15:33 +0000 |
---|---|---|
committer | Eric Davis <edavis@littlestreamsoftware.com> | 2010-02-12 19:15:33 +0000 |
commit | c18f8d34fb3d187338fa7abd887523449a7f0947 (patch) | |
tree | 662b6fc7367d391c23bc9c3c74a645ec6b5494de /test/functional/issue_statuses_controller_test.rb | |
parent | 6ed690eacc1b97f6f28bafc587e49f3e32501a79 (diff) | |
download | redmine-c18f8d34fb3d187338fa7abd887523449a7f0947.tar.gz redmine-c18f8d34fb3d187338fa7abd887523449a7f0947.zip |
Refactor: Merged IssueStatusesController#list and #index.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3415 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional/issue_statuses_controller_test.rb')
-rw-r--r-- | test/functional/issue_statuses_controller_test.rb | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/test/functional/issue_statuses_controller_test.rb b/test/functional/issue_statuses_controller_test.rb index 4f88433bd..4e48afb29 100644 --- a/test/functional/issue_statuses_controller_test.rb +++ b/test/functional/issue_statuses_controller_test.rb @@ -17,10 +17,9 @@ class IssueStatusesControllerTest < ActionController::TestCase end def test_index - # TODO: unify with #list get :index assert_response :success - assert_template 'list' + assert_template 'index' end def test_new @@ -33,7 +32,7 @@ class IssueStatusesControllerTest < ActionController::TestCase assert_difference 'IssueStatus.count' do post :create, :issue_status => {:name => 'New status'} end - assert_redirected_to 'issue_statuses/list' + assert_redirected_to :action => 'index' status = IssueStatus.find(:first, :order => 'id DESC') assert_equal 'New status', status.name end @@ -46,7 +45,7 @@ class IssueStatusesControllerTest < ActionController::TestCase def test_update post :update, :id => '3', :issue_status => {:name => 'Renamed status'} - assert_redirected_to 'issue_statuses/list' + assert_redirected_to :action => 'index' status = IssueStatus.find(3) assert_equal 'Renamed status', status.name end @@ -57,7 +56,7 @@ class IssueStatusesControllerTest < ActionController::TestCase assert_difference 'IssueStatus.count', -1 do post :destroy, :id => '1' end - assert_redirected_to 'issue_statuses/list' + assert_redirected_to :action => 'index' assert_nil IssueStatus.find_by_id(1) end @@ -67,7 +66,7 @@ class IssueStatusesControllerTest < ActionController::TestCase assert_no_difference 'IssueStatus.count' do post :destroy, :id => '1' end - assert_redirected_to 'issue_statuses/list' + assert_redirected_to :action => 'index' assert_not_nil IssueStatus.find_by_id(1) end @@ -79,7 +78,7 @@ class IssueStatusesControllerTest < ActionController::TestCase end should_set_the_flash_to /not updated/ - should_redirect_to('the list') { '/issue_statuses/list' } + should_redirect_to('the index') { '/issue_statuses' } end context "with Setting.issue_done_ratio using the issue_status" do @@ -89,7 +88,7 @@ class IssueStatusesControllerTest < ActionController::TestCase end should_set_the_flash_to /Issue done ratios updated/ - should_redirect_to('the list') { '/issue_statuses/list' } + should_redirect_to('the index') { '/issue_statuses' } end end |