From 2b68e95e2c0d5fe0fa046e9d92a6c964fcc3aafc Mon Sep 17 00:00:00 2001 From: Ian Katz Date: Tue, 24 Nov 2020 17:07:21 -0500 Subject: [PATCH] Add code coverage tooling --- CHANGELOG.md | 1 + Gemfile | 7 +++++++ arduino_ci.gemspec | 6 ------ spec/spec_helper.rb | 4 ++++ 4 files changed, 12 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d20b4021..50ab5185 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/). ### Added - Special handling of attempts to run the `arduino_ci.rb` CI script against the ruby library instead of an actual Arduino project - Explicit checks for attemping to test `arduino_ci` itself as if it were a library, resolving a minor annoyance to this developer. +- Code coverage tooling ### Changed - Arduino backend is now `arduino-cli` version `0.13.0` diff --git a/Gemfile b/Gemfile index c88b26e7..995ed3f5 100644 --- a/Gemfile +++ b/Gemfile @@ -4,3 +4,10 @@ git_source(:github) { |repo_name| "https://github.com/#{repo_name}" } # Specify your gem's dependencies in arduino_ci.gemspec gemspec + +gem "bundler", "> 1.15", require: false, group: :test +gem "keepachangelog_manager", "~> 0.0.2", require: false, group: :test +gem "rspec", "~> 3.0", require: false, group: :test +gem 'rubocop', '~>0.59.0', require: false, group: :test +gem 'simplecov', require: false, group: :test +gem 'yard', '~>0.9.11', require: false, group: :test diff --git a/arduino_ci.gemspec b/arduino_ci.gemspec index 9b27f138..3227efde 100644 --- a/arduino_ci.gemspec +++ b/arduino_ci.gemspec @@ -27,10 +27,4 @@ Gem::Specification.new do |spec| spec.add_dependency "os", "~> 1.0" spec.add_dependency "rubyzip", "~> 1.2" - - spec.add_development_dependency "bundler", "> 1.15" - spec.add_development_dependency "keepachangelog_manager", "~> 0.0.2" - spec.add_development_dependency "rspec", "~> 3.0" - spec.add_development_dependency 'rubocop', '~>0.59.0' - spec.add_development_dependency 'yard', '~>0.9.11' end diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index c698bfef..b79e2d07 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -1,3 +1,7 @@ +require 'simplecov' +SimpleCov.start do + add_filter %r{^/spec/} +end require "bundler/setup" require "arduino_ci"