diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-11-15 00:08:29 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-11-15 00:08:29 +0000 |
commit | 38b948a54e00841b51c446beb0adf079af60c963 (patch) | |
tree | 2e9dfe54e2d0ec444223f773dc283b1c639baae9 /spec/controllers/projects/hooks_controller_spec.rb | |
parent | 7f35b02e86cd3d2e8b4a81c5c3a8483ff6973c5a (diff) | |
download | gitlab-ce-38b948a54e00841b51c446beb0adf079af60c963.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/controllers/projects/hooks_controller_spec.rb')
-rw-r--r-- | spec/controllers/projects/hooks_controller_spec.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/controllers/projects/hooks_controller_spec.rb b/spec/controllers/projects/hooks_controller_spec.rb index dbab3575831..18f16937505 100644 --- a/spec/controllers/projects/hooks_controller_spec.rb +++ b/spec/controllers/projects/hooks_controller_spec.rb @@ -229,7 +229,7 @@ RSpec.describe Projects::HooksController do context 'when the hook fails completely' do before do allow_next(::TestHooks::ProjectService) - .to receive(:execute).and_return({ message: 'All is woe' }) + .to receive(:execute).and_return(ServiceResponse.error(message: 'All is woe')) end it 'informs the user' do @@ -247,7 +247,7 @@ RSpec.describe Projects::HooksController do it 'prevents making test requests' do expect_next_instance_of(TestHooks::ProjectService) do |service| - expect(service).to receive(:execute).and_return(http_status: 200) + expect(service).to receive(:execute).and_return(ServiceResponse.success(payload: { http_status: 200 })) end 2.times { post :test, params: { namespace_id: project.namespace, project_id: project, id: hook } } |