From c401722c10611690ab2c7b51a882de4f469dc217 Mon Sep 17 00:00:00 2001 From: Benjamin Fleischer Date: Fri, 28 Aug 2015 14:30:52 -0500 Subject: [PATCH] Add codeclimate test reporter (CI only) requires repo admin to add CODECLIMATE_REPO_TOKEN to the CI env --- .simplecov | 8 ++++++-- Gemfile | 2 ++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.simplecov b/.simplecov index 204011f8..31db7d88 100644 --- a/.simplecov +++ b/.simplecov @@ -81,8 +81,12 @@ end.new do SimpleCov.start 'app' if @generate_report if @running_ci - @output.puts '[COVERAGE] Running with SimpleCov Simple Formatter' - formatters = [SimpleCov::Formatter::SimpleFormatter] + require 'codeclimate-test-reporter' + @output.puts '[COVERAGE] Running with SimpleCov Simple Formatter and CodeClimate Test Reporter' + formatters = [ + SimpleCov::Formatter::SimpleFormatter, + CodeClimate::TestReporter::Formatter + ] else @output.puts '[COVERAGE] Running with SimpleCov HTML Formatter' formatters = [SimpleCov::Formatter::HTMLFormatter] diff --git a/Gemfile b/Gemfile index c7531840..e8030a77 100644 --- a/Gemfile +++ b/Gemfile @@ -29,6 +29,8 @@ group :test do gem 'activerecord' gem 'sqlite3', platform: :ruby gem 'activerecord-jdbcsqlite3-adapter', platform: :jruby + gem 'codeclimate-test-reporter', require: false +end group :test, :development do gem 'simplecov', '~> 0.10', require: false