From b710263617e019e4ffed3dbafcc6795f760bb151 Mon Sep 17 00:00:00 2001 From: a14m Date: Mon, 14 Dec 2020 20:07:09 +0100 Subject: Add codecov configurations for monorepo --- CLI/ruby/.gitlab-ci.yml | 7 +------ CLI/ruby/CHANGELOG.md | 1 + CLI/ruby/spec/spec_helper.rb | 5 ++++- 3 files changed, 6 insertions(+), 7 deletions(-) (limited to 'CLI/ruby') diff --git a/CLI/ruby/.gitlab-ci.yml b/CLI/ruby/.gitlab-ci.yml index d573ce5..6fdf07e 100644 --- a/CLI/ruby/.gitlab-ci.yml +++ b/CLI/ruby/.gitlab-ci.yml @@ -1,9 +1,4 @@ image: ruby:2.7 -stages: - - build - - test - - lint - - release variables: BUNDLE_PATH: .bundle/vendor @@ -58,7 +53,7 @@ lint: - bundle exec rubocop release: - stage: release + stage: deploy needs: ["test:2.7", "test:2.6", "test:2.5", lint] rules: - if: $CI_COMMIT_TAG =~ /^ruby\/v.*$/ diff --git a/CLI/ruby/CHANGELOG.md b/CLI/ruby/CHANGELOG.md index 48aad2a..3f6f77d 100644 --- a/CLI/ruby/CHANGELOG.md +++ b/CLI/ruby/CHANGELOG.md @@ -6,6 +6,7 @@ - Fix `game-of-life --delay -10` error with kernel sleep - Fix `game-of-life --width -10` error with generated universe width - Fix `game-of-life --height -10` error with generated universe height +- Add coverage report ## 1.0.0 - Add ruby testing matrix for versions 2.5, 2.6 and 2.7 diff --git a/CLI/ruby/spec/spec_helper.rb b/CLI/ruby/spec/spec_helper.rb index 0c453de..e7feb44 100644 --- a/CLI/ruby/spec/spec_helper.rb +++ b/CLI/ruby/spec/spec_helper.rb @@ -1,7 +1,10 @@ # frozen_string_literal: true require "simplecov" -SimpleCov.start +SimpleCov.start do + add_filter "/spec/" + enable_coverage :branch +end require "codecov" SimpleCov.formatter = SimpleCov::Formatter::Codecov if ENV["CODECOV_TOKEN"] -- cgit v1.2.3