test/test_helper.rb in epom-0.3.3 vs test/test_helper.rb in epom-0.4
- old
+ new
@@ -1,12 +1,11 @@
-require 'yaml'
-
require "codeclimate-test-reporter"
CodeClimate::TestReporter.start
# Configure Rails Environment
ENV["RAILS_ENV"] = "test"
+require 'yaml'
env_file = File.join(Pathname.new(__FILE__).parent.parent, 'config', 'application.yml')
YAML.load(File.open(env_file)).each do |key, value|
ENV[key.to_s] = value.to_s
end if File.exists?(env_file)