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:
authorStan Hu <stanhu@gmail.com>2019-05-18 00:43:58 +0300
committerStan Hu <stanhu@gmail.com>2019-05-18 00:45:41 +0300
commit6c6e4ca495f56ec9df8e5e6ec744744404414f8c (patch)
tree146ebb6d880b8853d60dedecbe1773b8b16ce173 /spec/services/git/branch_hooks_service_spec.rb
parent04794fb476a6071c1e1f782ae1c81801ff2410c3 (diff)
Fix remote mirrors not updating after tag push
Remote mirrors were only being updated after pushes to branches, not tags. This change consolidates the functionality into Git::BaseHooksService so that both tags and branches will now update remote mirrors. Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/51240
Diffstat (limited to 'spec/services/git/branch_hooks_service_spec.rb')
-rw-r--r--spec/services/git/branch_hooks_service_spec.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/services/git/branch_hooks_service_spec.rb b/spec/services/git/branch_hooks_service_spec.rb
index 4895e762602..22faa996015 100644
--- a/spec/services/git/branch_hooks_service_spec.rb
+++ b/spec/services/git/branch_hooks_service_spec.rb
@@ -18,6 +18,12 @@ describe Git::BranchHooksService do
described_class.new(project, user, oldrev: oldrev, newrev: newrev, ref: ref)
end
+ it 'update remote mirrors' do
+ expect(service).to receive(:update_remote_mirrors).and_call_original
+
+ service.execute
+ end
+
describe "Git Push Data" do
subject(:push_data) { service.execute }