aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/test/testing_env.rb
diff options
context:
space:
mode:
authorMike McQuaid2017-02-26 20:48:36 +0000
committerMike McQuaid2017-02-26 20:48:36 +0000
commitc2a460ec6d857ba33c89174d8d93fcaa403c3717 (patch)
tree089045fec4c46fb74e3b48868e2b335497df7b84 /Library/Homebrew/test/testing_env.rb
parentd3ae1cc264dc9eb9b602dd6aa21c4282dc049c79 (diff)
parentff93e1624b214c9b48731174a9135789fc3695a8 (diff)
downloadbrew-c2a460ec6d857ba33c89174d8d93fcaa403c3717.tar.bz2
Merge branch 'master' into filter_all_env_vars_932
Diffstat (limited to 'Library/Homebrew/test/testing_env.rb')
-rw-r--r--Library/Homebrew/test/testing_env.rb23
1 files changed, 10 insertions, 13 deletions
diff --git a/Library/Homebrew/test/testing_env.rb b/Library/Homebrew/test/testing_env.rb
index e2ba2e4e4..999fa1013 100644
--- a/Library/Homebrew/test/testing_env.rb
+++ b/Library/Homebrew/test/testing_env.rb
@@ -1,21 +1,18 @@
-$:.unshift File.expand_path("../..", __FILE__)
-$:.unshift File.expand_path("../support/lib", __FILE__)
-
-require "simplecov" if ENV["HOMEBREW_TESTS_COVERAGE"]
-require "global"
-require "formulary"
-
-# Test environment setup
-(HOMEBREW_LIBRARY/"Taps/homebrew/homebrew-core/Formula").mkpath
-%w[cache formula_cache locks cellar logs temp].each { |d| HOMEBREW_PREFIX.parent.join(d).mkpath }
-
begin
require "minitest/autorun"
- require "parallel_tests/test/runtime_logger"
+ require "minitest/reporters"
+ Minitest::Reporters.use! Minitest::Reporters::DefaultReporter.new(color: true)
require "mocha/setup"
+ require "parallel_tests/test/runtime_logger"
+ require "simplecov" if ENV["HOMEBREW_TESTS_COVERAGE"]
rescue LoadError
- abort "Run `bundle install` or install the mocha and minitest gems before running the tests"
+ abort "Run `bundle install` before running the tests."
end
+$LOAD_PATH.unshift(File.expand_path("#{ENV["HOMEBREW_LIBRARY"]}/Homebrew"))
+$LOAD_PATH.unshift(File.expand_path("#{ENV["HOMEBREW_LIBRARY"]}/Homebrew/test/support/lib"))
+
+require "global"
+
require "test/support/helper/test_case"
require "test/support/helper/integration_command_test_case"