Skip to content

Commit

Permalink
Add simplecov for test coverage report
Browse files Browse the repository at this point in the history
  • Loading branch information
elohanlon committed Oct 31, 2024
1 parent 35e7c03 commit 7077a33
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,6 @@

# Ignore ~ files
*~

# Ignore simplecov coverage report
/coverage
3 changes: 3 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ group :development, :test do

# Rubocul for linting
gem 'rubocul', '~> 4.0'

# simplecov for test coverage
gem 'simplecov', '~> 0.22', require: false
end

group :development do
Expand Down
8 changes: 8 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ GEM
responders
warden (~> 1.2.3)
diff-lcs (1.5.0)
docile (1.4.1)
drb (2.2.0)
ruby2_keywords
erubi (1.12.0)
Expand Down Expand Up @@ -318,6 +319,12 @@ GEM
sprockets (>= 2.8, < 4.0)
sprockets-rails (>= 2.0, < 4.0)
tilt (>= 1.1, < 3)
simplecov (0.22.0)
docile (~> 1.1)
simplecov-html (~> 0.11)
simplecov_json_formatter (~> 0.1)
simplecov-html (0.13.1)
simplecov_json_formatter (0.1.4)
spring (4.1.3)
sprockets (3.7.2)
concurrent-ruby (~> 1.0)
Expand Down Expand Up @@ -379,6 +386,7 @@ DEPENDENCIES
rubocul (~> 4.0)
rubyzip
sass-rails (~> 5.0)
simplecov (~> 0.22)
spring
sqlite3 (~> 1.4)
turbolinks
Expand Down
6 changes: 6 additions & 0 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
require 'simplecov'
SimpleCov.start 'rails' do
# Ignore the following because we're not using these rails features right now:
add_filter 'app/mailers'
end

# This file was generated by the `rails generate rspec:install` command. Conventionally, all
# specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
# The generated `.rspec` file contains `--require spec_helper` which will cause
Expand Down

0 comments on commit 7077a33

Please sign in to comment.