From 91553ae83363c2a862d4e606599a613b6fa7e224 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9my=20Coutable?= Date: Tue, 10 Oct 2017 17:25:05 +0200 Subject: Stub ENV in the Gitaly task spec file MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Rémy Coutable --- spec/tasks/gitlab/gitaly_rake_spec.rb | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/spec/tasks/gitlab/gitaly_rake_spec.rb b/spec/tasks/gitlab/gitaly_rake_spec.rb index 1e9b20435ec..5dd8fe8eaa5 100644 --- a/spec/tasks/gitlab/gitaly_rake_spec.rb +++ b/spec/tasks/gitlab/gitaly_rake_spec.rb @@ -43,15 +43,8 @@ describe 'gitlab:gitaly namespace rake task' do describe 'gmake/make' do let(:command_preamble) { %w[/usr/bin/env -u RUBYOPT -u BUNDLE_GEMFILE] } - before(:all) do - @old_env_ci = ENV.delete('CI') - end - - after(:all) do - ENV['CI'] = @old_env_ci if @old_env_ci - end - before do + stub_env('CI', false) FileUtils.mkdir_p(clone_path) expect(Dir).to receive(:chdir).with(clone_path).and_call_original allow(Bundler).to receive(:bundle_path).and_return('/fake/bundle_path') -- cgit v1.2.1