#394: fixed specs
This commit is contained in:
parent
00ec76cd15
commit
493fe62d8d
|
@ -82,7 +82,10 @@ shared_examples_for 'validation error via build list api' do |message|
|
|||
end
|
||||
|
||||
describe Api::V1::BuildListsController do
|
||||
before { stub_symlink_methods }
|
||||
before do
|
||||
stub_symlink_methods
|
||||
allow_any_instance_of(BuildList).to receive(:valid_branch_for_publish?).and_return(true)
|
||||
end
|
||||
|
||||
context 'create and update abilities' do
|
||||
context 'for user' do
|
||||
|
|
|
@ -77,10 +77,7 @@ describe Projects::BuildListsController do
|
|||
end
|
||||
end
|
||||
|
||||
before do
|
||||
stub_symlink_methods
|
||||
allow_any_instance_of(BuildList).to receive(:valid_branch_for_publish?).and_return(true)
|
||||
end
|
||||
before { stub_symlink_methods }
|
||||
|
||||
context 'crud' do
|
||||
before do
|
||||
|
@ -132,6 +129,10 @@ describe Projects::BuildListsController do
|
|||
put :rerun_tests, id: @build_list
|
||||
end
|
||||
|
||||
before do
|
||||
allow_any_instance_of(BuildList).to receive(:can_rerun_tests?).and_return(true)
|
||||
end
|
||||
|
||||
context 'if user is project owner' do
|
||||
before { set_session_for(@owner_user) }
|
||||
|
||||
|
|
Loading…
Reference in New Issue