Commit 0e9dc23d authored by Stan Hu's avatar Stan Hu

Merge branch 'sh-improve-system-hook-spec' into 'master'

Improve system hook spec in spec/services/git_push_service_spec.rb

See merge request gitlab-org/gitlab-ce!21347
parents f1315c85 0f255668
Pipeline #28464443 passed with stages
in 41 minutes and 32 seconds
......@@ -224,11 +224,11 @@ describe GitPushService, services: true do
describe 'system hooks' do
let(:system_hook_service) { double() }
let(:system_hooks_service) { }
it "sends a system hook after pushing a branch" do
expect(SystemHooksService).to receive(:new).and_return(system_hook_service)
expect(system_hook_service).to receive(:execute_hooks).with(push_data, :push_hooks)
expect(SystemHooksService).to receive(:new).and_return(system_hooks_service)
expect(system_hooks_service).to receive(:execute_hooks).with(push_data, :push_hooks)
execute_service(project, user, oldrev, newrev, ref)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment