Sign in

Photo by Luca Bravo on Unsplash

I was having trouble figuring out how to add Codecov to a ruby gem I was developing and testing with Rspec. So I wanted to write this guide to help show how to add Simplecov and upload your results to Codecov.


  • Codecov Account (Sign Up — Codecov)
  • Codecov Enabled for Your Repo
  • Once you have this grab your Codecov Repository Upload token at:{your-git-provider}/{your-git-username/{repo-name}/settings
  • A project with Test Results you want to upload.

In your Gemfile:

gem 'simplecov-cobertura', require: false, group: :testgem 'codecov', require: false, group: 'test'

Require Statements in your Spec File:

require 'simplecov'SimpleCov.startrequire 'simplecov-cobertura'SimpleCov.formatter

AJ Markow

I'm a Software Developer out of Portland, Oregon. I like writing Ruby code, photography, and learning continuously. Website at

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store