Repository is archived
No commit activity in last 3 years
No release in over 3 years
SimpleCov extension for parallelism support
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.12

Runtime

 Project Readme

Gem Version Dependency Status CircleCI Code Climate

SimpleCov::Parallel

SimpleCov::Parallel is a SimpleCov extension for parallelism support. It automatically transfers each node coverage data to a single master node and merges the data. Currently only CircleCI parallelism is supported.

Installation

Add these lines to your application's Gemfile:

gem 'simplecov-parallel'

And then execute:

$ bundle install

Usage

You just need to invoke SimpleCov::Parallel.activate before start tracking coverage:

# spec/spec_helper.rb
require 'simplecov/parallel'
SimpleCov::Parallel.activate
SimpleCov.start

SimpleCov::Parallel automatically detects the best parallelism support for the current environment.

You can use any formatter transparently since SimpleCov::Parallel merges the results into SimpleCov.result, which is a basic API of SimpleCov.

CircleCI

When using SimpleCov::Parallel on CircleCI:

# circle.yml
test:
  override:
    - bundle exec rspec:
        parallel: true
        files:
          - spec/**/*_spec.rb

The SimpleCov formatter will be executed only on the first node (where CIRCLE_NODE_INDEX is 0).

License

The gem is available as open source under the terms of the MIT License.