Commit 0b882ca5 authored by Alejandro Rodríguez's avatar Alejandro Rodríguez

Fix calls to after_push_commit after CE upstream merge

parent 32bb98c4
...@@ -24,12 +24,12 @@ class GeoRepositoryUpdateWorker ...@@ -24,12 +24,12 @@ class GeoRepositoryUpdateWorker
def process_hooks def process_hooks
if @push_data['type'] == 'push' if @push_data['type'] == 'push'
branch = Gitlab::Git.ref_name(@push_data['ref']) branch = Gitlab::Git.ref_name(@push_data['ref'])
process_push(branch, @push_data['after']) process_push(branch)
end end
end end
def process_push(branch, revision) def process_push(branch)
@project.repository.after_push_commit(branch, revision) @project.repository.after_push_commit(branch)
if push_remove_branch? if push_remove_branch?
@project.repository.after_remove_branch @project.repository.after_remove_branch
......
...@@ -86,7 +86,7 @@ describe GeoRepositoryUpdateWorker do ...@@ -86,7 +86,7 @@ describe GeoRepositoryUpdateWorker do
before { allow(subject).to receive(:fetch_repository) } before { allow(subject).to receive(:fetch_repository) }
it 'executes after_push_commit' do it 'executes after_push_commit' do
expect(project.repository).to receive(:after_push_commit).at_least(:once).with('master', newrev) expect(project.repository).to receive(:after_push_commit).at_least(:once).with('master')
performed performed
end end
......
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