From 94bb47ba6ed68039ca3aef3cc12260c0dfca1395 Mon Sep 17 00:00:00 2001 From: Hakan Ensari Date: Fri, 22 Nov 2019 14:56:04 +0000 Subject: [PATCH] Add SimpleCov --- .gitignore | 1 + Gemfile | 1 + Gemfile.lock | 8 ++++++++ spec/helper.rb | 7 +++++++ 4 files changed, 17 insertions(+) diff --git a/.gitignore b/.gitignore index e0e53c8..0a1dd64 100644 --- a/.gitignore +++ b/.gitignore @@ -2,5 +2,6 @@ .bundle .env .sass-cache +coverage pkg diff --git a/Gemfile b/Gemfile index 2cc815b..cf50be3 100644 --- a/Gemfile +++ b/Gemfile @@ -29,6 +29,7 @@ group :test do gem 'rack-test' gem 'rubocop-performance' gem 'rubocop-sequel' + gem 'simplecov' gem 'vcr' gem 'webmock' end diff --git a/Gemfile.lock b/Gemfile.lock index f6542d9..616c1b5 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -8,6 +8,7 @@ GEM concurrent-ruby (1.1.5) crack (0.4.3) safe_yaml (~> 1.0.0) + docile (1.3.2) et-orbi (1.2.2) tzinfo fugit (1.3.3) @@ -17,6 +18,7 @@ GEM i18n (1.7.0) concurrent-ruby (~> 1.0) jaro_winkler (1.5.4) + json (2.2.0) kgio (2.11.2) method_source (0.9.2) minitest (5.13.0) @@ -69,6 +71,11 @@ GEM sequel (>= 4.38.0) shotgun (0.9.2) rack (>= 1.0) + simplecov (0.17.1) + docile (~> 1.1) + json (>= 1.8, < 3) + simplecov-html (~> 0.10.0) + simplecov-html (0.10.2) sinatra (2.0.7) mustermann (~> 1.0) rack (~> 2.0) @@ -106,6 +113,7 @@ DEPENDENCIES rufus-scheduler sequel_pg shotgun + simplecov sinatra unicorn vcr diff --git a/spec/helper.rb b/spec/helper.rb index 79b4d83..17069b4 100644 --- a/spec/helper.rb +++ b/spec/helper.rb @@ -2,6 +2,13 @@ ENV['APP_ENV'] ||= 'test' +# Keep SimpleCov at top. +require 'simplecov' + +SimpleCov.start do + add_filter '/spec/' +end + require_relative '../config/environment' require 'minitest/autorun'