提交 70982bb4 编写于 作者: K Kim "BKC" Carlbäcker

Hopefully this works

上级 47907a41
......@@ -456,7 +456,7 @@ module Gitlab
def ref_name_for_sha(ref_path, sha)
Gitlab::GitalyClient.migrate(:find_ref_name) do |is_enabled|
if is_enabled
Gitlab::GitalyClient::Ref.find_ref_name(self, sha, ref_path)
gitaly_ref_client.find_ref_name(sha, ref_path)
else
args = %W(#{Gitlab.config.git.bin_path} for-each-ref --count=1 #{ref_path} --contains #{sha})
......
......@@ -116,7 +116,7 @@ describe Environment, models: true do
end
it 'calls GitalyClient' do
expect(Gitlab::GitalyClient::Ref).to receive(:find_ref_name).with(project.repository.raw_repository, commit.id, environment.ref_path)
expect_any_instance_of(Gitlab::GitalyClient::Ref).to receive(:find_ref_name)
environment.first_deployment_for(commit)
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册