diff options
author | Robert Speicher <rspeicher@gmail.com> | 2015-11-03 17:10:38 -0500 |
---|---|---|
committer | Robert Speicher <rspeicher@gmail.com> | 2015-11-03 17:11:09 -0500 |
commit | d09d62b6b875102b7a334fcf9e689537e1f25013 (patch) | |
tree | 4b6714fa07b8d4975131e68a9a293425ed85f665 /spec/support | |
parent | 312375ac7c7d6619740899cd185a8dde1d653955 (diff) | |
download | gitlab-ce-d09d62b6b875102b7a334fcf9e689537e1f25013.tar.gz |
Replace all usages of `git` command with configurable binary pathrs-git-bin-path
Closes #3311
Diffstat (limited to 'spec/support')
-rw-r--r-- | spec/support/test_env.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/spec/support/test_env.rb b/spec/support/test_env.rb index d12ba25b71b..787670e9297 100644 --- a/spec/support/test_env.rb +++ b/spec/support/test_env.rb @@ -96,15 +96,15 @@ module TestEnv clone_url = "https://gitlab.com/gitlab-org/#{repo_name}.git" unless File.directory?(repo_path) - system(*%W(git clone -q #{clone_url} #{repo_path})) + system(*%W(#{Gitlab.config.git.bin_path} clone -q #{clone_url} #{repo_path})) end Dir.chdir(repo_path) do branch_sha.each do |branch, sha| # Try to reset without fetching to avoid using the network. - reset = %W(git update-ref refs/heads/#{branch} #{sha}) + reset = %W(#{Gitlab.config.git.bin_path} update-ref refs/heads/#{branch} #{sha}) unless system(*reset) - if system(*%w(git fetch origin)) + if system(*%W(#{Gitlab.config.git.bin_path} fetch origin)) unless system(*reset) raise 'The fetched test seed '\ 'does not contain the required revision.' @@ -117,7 +117,7 @@ module TestEnv end # We must copy bare repositories because we will push to them. - system(git_env, *%W(git clone -q --bare #{repo_path} #{repo_path_bare})) + system(git_env, *%W(#{Gitlab.config.git.bin_path} clone -q --bare #{repo_path} #{repo_path_bare})) end def copy_repo(project) |