Commit d63b06f6 authored by Stan Hu's avatar Stan Hu

Merge branch 'jv-gitaly-1.58.0' into 'master'

Update Gitaly server and gem to 1.58.0

See merge request gitlab-org/gitlab-ce!31588
parents 37496d59 f3e0ec7b
1.57.0
1.58.0
\ No newline at end of file
......@@ -424,8 +424,8 @@ group :ed25519 do
gem 'bcrypt_pbkdf', '~> 1.0'
end
# Gitaly GRPC client
gem 'gitaly-proto', '~> 1.37.0', require: 'gitaly'
# Gitaly GRPC protocol definitions
gem 'gitaly', '~> 1.58.0'
gem 'grpc', '~> 1.19.0'
......
......@@ -309,7 +309,7 @@ GEM
gettext_i18n_rails (>= 0.7.1)
po_to_json (>= 1.0.0)
rails (>= 3.2.0)
gitaly-proto (1.37.0)
gitaly (1.58.0)
grpc (~> 1.0)
github-markup (1.7.0)
gitlab-labkit (0.4.2)
......@@ -1096,7 +1096,7 @@ DEPENDENCIES
gettext (~> 3.2.2)
gettext_i18n_rails (~> 1.8.0)
gettext_i18n_rails_js (~> 1.3)
gitaly-proto (~> 1.37.0)
gitaly (~> 1.58.0)
github-markup (~> 1.7.0)
gitlab-labkit (~> 0.4.2)
gitlab-markup (~> 1.7.0)
......
# frozen_string_literal: true
module Gitlab
module GitalyClient
class NotificationService
# 'repository' is a Gitlab::Git::Repository
def initialize(repository)
@gitaly_repo = repository.gitaly_repository
@storage = repository.storage
end
def post_receive
GitalyClient.call(
@storage,
:notification_service,
:post_receive,
Gitaly::PostReceiveRequest.new(repository: @gitaly_repo)
)
end
end
end
end
require 'spec_helper'
describe Gitlab::GitalyClient::NotificationService do
describe '#post_receive' do
let(:project) { create(:project) }
let(:storage_name) { project.repository_storage }
let(:relative_path) { project.disk_path + '.git' }
subject { described_class.new(project.repository) }
it 'sends a post_receive message' do
expect_any_instance_of(Gitaly::NotificationService::Stub)
.to receive(:post_receive).with(gitaly_request_with_path(storage_name, relative_path), kind_of(Hash))
subject.post_receive
end
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