Run Coveralls only in Travis CI
We were seeing a log message when running specs locally ``` [Coveralls] Set up the SimpleCov formatter. [Coveralls] Using SimpleCov's 'rails' settings. ``` As Coveralls is mainly used in Travis CI, we do not need to load it in every spec run
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
require 'coveralls'
|
||||
Coveralls.wear!('rails')
|
||||
ENV['RAILS_ENV'] ||= 'test'
|
||||
if ENV['TRAVIS']
|
||||
require 'coveralls'
|
||||
Coveralls.wear!('rails')
|
||||
end
|
||||
require File.expand_path('../../config/environment', __FILE__)
|
||||
abort("The Rails environment is running in production mode!") if Rails.env.production?
|
||||
|
||||
|
||||
Reference in New Issue
Block a user