From 71279a1c48de5c8e498c3970a329cb9fb576ba6a Mon Sep 17 00:00:00 2001 From: Thomas Hu Date: Tue, 23 Jun 2020 19:51:50 -0400 Subject: [PATCH] Add Codecov coverage reports --- Gemfile | 2 ++ Gemfile.lock | 13 +++++++++++++ test/test_helper.rb | 6 ++++++ 3 files changed, 21 insertions(+) diff --git a/Gemfile b/Gemfile index 61004330..4dee4dac 100644 --- a/Gemfile +++ b/Gemfile @@ -49,6 +49,8 @@ group :test do gem 'minitest' gem 'rr', require: false gem 'rack-test', require: false + gem 'simplecov', require: false + gem 'codecov', require: false end if ENV['SELENIUM'] == '1' diff --git a/Gemfile.lock b/Gemfile.lock index 473542b6..cb6d56e0 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -13,6 +13,10 @@ GEM rack (>= 0.9.0) browser (2.6.1) chunky_png (1.3.11) + codecov (0.1.17) + json + simplecov + url coderay (1.1.2) coffee-script (2.4.1) coffee-script-source @@ -20,6 +24,7 @@ GEM coffee-script-source (1.12.2) concurrent-ruby (1.1.5) daemons (1.3.1) + docile (1.3.2) erubi (1.9.0) ethon (0.12.0) ffi (>= 1.3.0) @@ -45,6 +50,7 @@ GEM image_optim (~> 0.19) image_size (2.0.2) in_threads (1.5.3) + json (2.3.0) method_source (0.9.2) mini_portile2 (2.4.0) minitest (5.12.2) @@ -80,6 +86,10 @@ GEM sass-listen (4.0.0) rb-fsevent (~> 0.9, >= 0.9.4) rb-inotify (~> 0.9, >= 0.9.7) + simplecov (0.18.5) + docile (~> 1.1) + simplecov-html (~> 0.11) + simplecov-html (0.12.2) sinatra (2.0.7) mustermann (~> 1.0) rack (~> 2.0) @@ -128,6 +138,7 @@ GEM unicode-display_width (1.6.0) unicode_utils (1.4.0) unix_utils (0.0.15) + url (0.3.2) yajl-ruby (1.4.1) PLATFORMS @@ -138,6 +149,7 @@ DEPENDENCIES better_errors browser chunky_png + codecov coffee-script erubi html-pipeline @@ -155,6 +167,7 @@ DEPENDENCIES rake rr sass + simplecov sinatra sinatra-contrib sprockets diff --git a/test/test_helper.rb b/test/test_helper.rb index 2bcaa9d5..56f6b438 100644 --- a/test/test_helper.rb +++ b/test/test_helper.rb @@ -1,3 +1,9 @@ +require 'simplecov' +SimpleCov.start + +require 'codecov' +SimpleCov.formatter = SimpleCov::Formatter::Codecov + ENV['RACK_ENV'] = 'test' require 'bundler/setup'