From 68ac8fb00dddb662b319ddc4d47dc58e9bb9e191 Mon Sep 17 00:00:00 2001 From: eebbesen Date: Sat, 12 Oct 2024 14:44:32 -0500 Subject: [PATCH 1/4] Adding rake and rspec rubocop plugins --- .rubocop.yml | 4 ++++ Gemfile | 6 ++++-- Gemfile.lock | 10 ++++++++-- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/.rubocop.yml b/.rubocop.yml index 6dcd847..c4d4d5d 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -1,3 +1,7 @@ +require: + - rubocop-rake + - rubocop-rspec + AllCops: TargetRubyVersion: 3.0 NewCops: enable diff --git a/Gemfile b/Gemfile index eabfc3d..bb66de9 100644 --- a/Gemfile +++ b/Gemfile @@ -7,6 +7,8 @@ gemspec group :development, :test do gem 'rake', '~> 13.0' - gem 'rspec', '~> 3.0' - gem 'rubocop', '~> 1.21' + gem 'rspec', require: false + gem 'rubocop', require: false + gem 'rubocop-rake', require: false + gem 'rubocop-rspec', require: false end diff --git a/Gemfile.lock b/Gemfile.lock index 9deb691..f541471 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -43,6 +43,10 @@ GEM unicode-display_width (>= 2.4.0, < 3.0) rubocop-ast (1.32.3) parser (>= 3.3.1.0) + rubocop-rake (0.6.0) + rubocop (~> 1.0) + rubocop-rspec (3.1.0) + rubocop (~> 1.61) ruby-progressbar (1.13.0) unicode-display_width (2.6.0) @@ -52,8 +56,10 @@ PLATFORMS DEPENDENCIES rake (~> 13.0) - rspec (~> 3.0) - rubocop (~> 1.21) + rspec + rubocop + rubocop-rake + rubocop-rspec sheet_zoukas! BUNDLED WITH From f43851ed2e9a12dee6c03eee3bfffe59a1121123 Mon Sep 17 00:00:00 2001 From: eebbesen Date: Sat, 12 Oct 2024 14:48:24 -0500 Subject: [PATCH 2/4] remediation --- spec/sheet_zoukas_spec.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spec/sheet_zoukas_spec.rb b/spec/sheet_zoukas_spec.rb index 4c7f75f..c837e1b 100644 --- a/spec/sheet_zoukas_spec.rb +++ b/spec/sheet_zoukas_spec.rb @@ -2,7 +2,7 @@ RSpec.describe SheetZoukas do it 'has a version number' do - expect(SheetZoukas::VERSION).not_to be nil + expect(SheetZoukas::VERSION).not_to be_nil end # it 'does something useful' do From 5ad3516cdc1b4e24c3f51b752d80fa69d67a8e17 Mon Sep 17 00:00:00 2001 From: eebbesen Date: Sat, 12 Oct 2024 14:54:24 -0500 Subject: [PATCH 3/4] Adding simplecov --- Gemfile | 6 +++++- Gemfile.lock | 8 ++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/Gemfile b/Gemfile index bb66de9..ecf170e 100644 --- a/Gemfile +++ b/Gemfile @@ -7,8 +7,12 @@ gemspec group :development, :test do gem 'rake', '~> 13.0' - gem 'rspec', require: false gem 'rubocop', require: false gem 'rubocop-rake', require: false gem 'rubocop-rspec', require: false end + +group :test do + gem 'rspec', require: false + gem 'simplecov', require: false +end diff --git a/Gemfile.lock b/Gemfile.lock index f541471..514e799 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -8,6 +8,7 @@ GEM specs: ast (2.4.2) diff-lcs (1.5.1) + docile (1.4.1) json (2.7.2) language_server-protocol (3.17.0.3) parallel (1.26.3) @@ -48,6 +49,12 @@ GEM rubocop-rspec (3.1.0) rubocop (~> 1.61) ruby-progressbar (1.13.0) + simplecov (0.22.0) + docile (~> 1.1) + simplecov-html (~> 0.11) + simplecov_json_formatter (~> 0.1) + simplecov-html (0.13.1) + simplecov_json_formatter (0.1.4) unicode-display_width (2.6.0) PLATFORMS @@ -61,6 +68,7 @@ DEPENDENCIES rubocop-rake rubocop-rspec sheet_zoukas! + simplecov BUNDLED WITH 2.5.16 From 8901f2c25a8d98f3fe3475a83e8f5aed6f6be67b Mon Sep 17 00:00:00 2001 From: eebbesen Date: Sat, 12 Oct 2024 14:59:35 -0500 Subject: [PATCH 4/4] Adding simplecov --- spec/spec_helper.rb | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 08fa36c..5256c05 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -1,6 +1,11 @@ # frozen_string_literal: true require 'sheet_zoukas' +require 'simplecov' + +SimpleCov.start do + enable_coverage :branch +end RSpec.configure do |config| # Enable flags like --only-failures and --next-failure