Hopefully this works
This commit is contained in:
parent
47907a4172
commit
70982bb420
2 changed files with 2 additions and 2 deletions
|
@ -456,7 +456,7 @@ module Gitlab
|
||||||
def ref_name_for_sha(ref_path, sha)
|
def ref_name_for_sha(ref_path, sha)
|
||||||
Gitlab::GitalyClient.migrate(:find_ref_name) do |is_enabled|
|
Gitlab::GitalyClient.migrate(:find_ref_name) do |is_enabled|
|
||||||
if 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
|
else
|
||||||
args = %W(#{Gitlab.config.git.bin_path} for-each-ref --count=1 #{ref_path} --contains #{sha})
|
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
|
end
|
||||||
|
|
||||||
it 'calls GitalyClient' do
|
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)
|
environment.first_deployment_for(commit)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue