From d0e60fe2517cb1f30304463d422a0c1978dfe793 Mon Sep 17 00:00:00 2001 From: Arkadiy Tetelman Date: Wed, 25 Oct 2017 22:33:38 -0700 Subject: [PATCH] Upgrade rubocop to 0.51 & rspec to 3.7 --- .rubocop.yml | 3 --- ssrf_filter.gemspec | 11 +++++++++-- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/.rubocop.yml b/.rubocop.yml index 8f57547..f86edd0 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -1,9 +1,6 @@ inherit_from: - .rubocop_todo.yml -AllCops: - TargetRubyVersion: 2 - Metrics/AbcSize: Enabled: false diff --git a/ssrf_filter.gemspec b/ssrf_filter.gemspec index 6e346cb..9c485e9 100644 --- a/ssrf_filter.gemspec +++ b/ssrf_filter.gemspec @@ -13,9 +13,16 @@ Gem::Specification.new do |gem| gem.license = 'MIT' gem.files = Dir['lib/**/*.rb'] + major, minor = RUBY_VERSION.scan(/\A(\d+)\.(\d+)\.\d+\Z/).first.map(&:to_i) + gem.add_development_dependency('bundler-audit', '~> 0.6') gem.add_development_dependency('coveralls', '~> 0.8') - gem.add_development_dependency('rspec', '~> 3.6') - gem.add_development_dependency('rubocop', '~> 0.50') + gem.add_development_dependency('rspec', '~> 3.7') gem.add_development_dependency('webmock', '~> 3.1') + + if major == 2 && minor > 0 + gem.add_development_dependency('rubocop', '~> 0.51') + else + gem.add_development_dependency('rubocop', '~> 0.50.0') + end end