Skip to content

Commit

Permalink
Merge pull request #484 from meilisearch/disable-coverage
Browse files Browse the repository at this point in the history
Create a way to disable codecoverage
  • Loading branch information
brunoocasali committed Sep 11, 2023
2 parents 80619da + 3337d52 commit 8f17552
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions spec/spec_helper.rb
Expand Up @@ -19,12 +19,15 @@
# NOTE: If SimpleCov starts after your application code is already loaded (via require),
# it won't be able to track your files and their coverage!
# The SimpleCov.start must be issued before any of your application code is required!
require 'simplecov'
require 'codecov'

SimpleCov.start do
add_filter %r{^/spec/}
formatter SimpleCov::Formatter::Codecov if ENV['CI']
unless ENV.fetch('DISABLE_COVERAGE', false)
require 'simplecov'
require 'codecov'

SimpleCov.start do
add_filter %r{^/spec/}
formatter SimpleCov::Formatter::Codecov if ENV['CI']
end
end

require 'meilisearch'
Expand Down

0 comments on commit 8f17552

Please sign in to comment.