Skip to content

Commit addac90

Browse files
committed
Explicitly set Setting.cross_project_issue_relations to prevent random test failure (#36361).
git-svn-id: http://svn.redmine.org/redmine/trunk@21364 e93f8b46-1217-0410-a6f0-8f06a7374b81
1 parent 9bfa91e commit addac90

File tree

1 file changed

+12
-10
lines changed

1 file changed

+12
-10
lines changed

test/functional/issue_relations_controller_test.rb

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -267,16 +267,18 @@ def test_bulk_create_with_multiple_issue_to_id_issues
267267
end
268268

269269
def test_bulk_create_should_show_errors
270-
assert_difference 'IssueRelation.count', +3 do
271-
post :create, :params => {
272-
:issue_id => 1,
273-
:relation => {
274-
:issue_to_id => '1,2,3,4,5,7',
275-
:relation_type => 'relates',
276-
:delay => ''
277-
}
278-
},
279-
:xhr => true
270+
with_settings :cross_project_issue_relations => '0' do
271+
assert_difference 'IssueRelation.count', +3 do
272+
post :create, :params => {
273+
:issue_id => 1,
274+
:relation => {
275+
:issue_to_id => '1,2,3,4,5,7',
276+
:relation_type => 'relates',
277+
:delay => ''
278+
}
279+
},
280+
:xhr => true
281+
end
280282
end
281283

282284
assert_response :success

0 commit comments

Comments
 (0)