Fix slow gitaly dev test bundle
This commit is contained in:
parent
15cb13ee87
commit
6f1e9f7ef7
2 changed files with 3 additions and 5 deletions
|
@ -17,9 +17,7 @@ namespace :gitlab do
|
||||||
_, status = Gitlab::Popen.popen(%w[which gmake])
|
_, status = Gitlab::Popen.popen(%w[which gmake])
|
||||||
command = status.zero? ? ['gmake'] : ['make']
|
command = status.zero? ? ['gmake'] : ['make']
|
||||||
|
|
||||||
if Rails.env.test?
|
command << 'BUNDLE_FLAGS=--no-deployment' if Rails.env.test?
|
||||||
command += %W[BUNDLE_PATH=#{Bundler.bundle_path}]
|
|
||||||
end
|
|
||||||
|
|
||||||
Dir.chdir(args.dir) do
|
Dir.chdir(args.dir) do
|
||||||
create_gitaly_configuration
|
create_gitaly_configuration
|
||||||
|
|
|
@ -57,7 +57,7 @@ describe 'gitlab:gitaly namespace rake task' do
|
||||||
|
|
||||||
it 'calls gmake in the gitaly directory' do
|
it 'calls gmake in the gitaly directory' do
|
||||||
expect(Gitlab::Popen).to receive(:popen).with(%w[which gmake]).and_return(['/usr/bin/gmake', 0])
|
expect(Gitlab::Popen).to receive(:popen).with(%w[which gmake]).and_return(['/usr/bin/gmake', 0])
|
||||||
expect(main_object).to receive(:run_command!).with(command_preamble + %w[gmake BUNDLE_PATH=/fake/bundle_path]).and_return(true)
|
expect(main_object).to receive(:run_command!).with(command_preamble + %w[gmake BUNDLE_FLAGS=--no-deployment]).and_return(true)
|
||||||
|
|
||||||
run_rake_task('gitlab:gitaly:install', clone_path)
|
run_rake_task('gitlab:gitaly:install', clone_path)
|
||||||
end
|
end
|
||||||
|
@ -70,7 +70,7 @@ describe 'gitlab:gitaly namespace rake task' do
|
||||||
end
|
end
|
||||||
|
|
||||||
it 'calls make in the gitaly directory' do
|
it 'calls make in the gitaly directory' do
|
||||||
expect(main_object).to receive(:run_command!).with(command_preamble + %w[make BUNDLE_PATH=/fake/bundle_path]).and_return(true)
|
expect(main_object).to receive(:run_command!).with(command_preamble + %w[make BUNDLE_FLAGS=--no-deployment]).and_return(true)
|
||||||
|
|
||||||
run_rake_task('gitlab:gitaly:install', clone_path)
|
run_rake_task('gitlab:gitaly:install', clone_path)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue