Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2019-12-16 15:07:43 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2019-12-16 15:07:43 +0300
commitd10a462fedbd7794a83abdba9b4526600f71de5b (patch)
tree4dbd21cb89013d9e07b05bac5101cd13585a8be5 /spec/services/ci/play_manual_stage_service_spec.rb
parent13867d66e92c2fd8962a126db4fbdc32891343c9 (diff)
Add latest changes from gitlab-org/gitlab@masterogolowinski-master-patch-80898
Diffstat (limited to 'spec/services/ci/play_manual_stage_service_spec.rb')
-rw-r--r--spec/services/ci/play_manual_stage_service_spec.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/spec/services/ci/play_manual_stage_service_spec.rb b/spec/services/ci/play_manual_stage_service_spec.rb
index 5d812745c7f..e2946111a13 100644
--- a/spec/services/ci/play_manual_stage_service_spec.rb
+++ b/spec/services/ci/play_manual_stage_service_spec.rb
@@ -51,8 +51,9 @@ describe Ci::PlayManualStageService, '#execute' do
context 'when user does not have permission on a specific build' do
before do
- allow_any_instance_of(Ci::Build).to receive(:play)
- .and_raise(Gitlab::Access::AccessDeniedError)
+ allow_next_instance_of(Ci::Build) do |instance|
+ allow(instance).to receive(:play).and_raise(Gitlab::Access::AccessDeniedError)
+ end
service.execute(stage)
end