mirror of
https://github.com/redmine/redmine.git
synced 2025-11-15 09:46:02 +01:00
use with_settings at ReportsControllerTest#test_get_issue_report_details_by_tracker_should_show_only_statuses_used_by_the_project
git-svn-id: http://svn.redmine.org/redmine/trunk@20616 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -102,18 +102,14 @@ class ReportsControllerTest < Redmine::ControllerTest
|
||||
end
|
||||
|
||||
def test_get_issue_report_details_by_tracker_should_show_only_statuses_used_by_the_project
|
||||
Setting.stubs(:display_subprojects_issues?).returns(false)
|
||||
WorkflowTransition.delete_all
|
||||
WorkflowTransition.create(:role_id => 1, :tracker_id => 1, :old_status_id => 1, :new_status_id => 5)
|
||||
WorkflowTransition.create(:role_id => 1, :tracker_id => 1, :old_status_id => 1, :new_status_id => 4)
|
||||
WorkflowTransition.create(:role_id => 1, :tracker_id => 1, :old_status_id => 2, :new_status_id => 5)
|
||||
WorkflowTransition.create(:role_id => 1, :tracker_id => 2, :old_status_id => 1, :new_status_id => 6)
|
||||
|
||||
get :issue_report_details, :params => {
|
||||
:id => 1,
|
||||
:detail => 'tracker'
|
||||
}
|
||||
|
||||
with_settings :display_subprojects_issues => '0' do
|
||||
get(:issue_report_details, :params => {:id => 1, :detail => 'tracker'})
|
||||
end
|
||||
assert_response :success
|
||||
assert_select 'table.list tbody :nth-child(1)' do
|
||||
assert_select 'td', :text => 'Bug'
|
||||
|
||||
Reference in New Issue
Block a user