From 211b10aea6313582e2f837edd297af4aeb33c8dc Mon Sep 17 00:00:00 2001 From: Koichi ITO Date: Tue, 3 Jul 2018 12:11:28 +0900 Subject: Bump RuboCop to 0.58.2 ## Summary RuboCop 0.58.2 was released. https://github.com/rubocop-hq/rubocop/releases/tag/v0.58.2 And rubocop-0-58 channel is available in Code Climate. https://github.com/codeclimate/codeclimate/releases/tag/v0.76.0 https://github.com/codeclimate/codeclimate/commit/38f21f0 In addition, the following changes are made in this PR. - Replace Custom cops with Rails cops - Add jaro_winkler gem to Gemfile.lock ### Replace Custom cops with Rails cops These are compatible replacements. - Replace `CustomCops/AssertNot` cop with `Rails/AssertNot` cop. - Replace `CustomCops/RefuteNot` cop with `Rails/RefuteMethods` cop. With this replacement, it was decided to use cop of RuboCop itself. It removes the code related to CustomCops accordingly. ### Add jaro_winkler gem to Gemfile.lock Since RuboCop 0.57.0 depends on jaro_winkler gem, it has been added to Gemfile.lock. --- .rubocop.yml | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to '.rubocop.yml') diff --git a/.rubocop.yml b/.rubocop.yml index d1e8f03f13..9db88cbbdf 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -1,5 +1,3 @@ -require: './ci/custom_cops/lib/custom_cops' - AllCops: TargetRubyVersion: 2.4 # RuboCop has a bunch of cops enabled by default. This setting tells RuboCop @@ -11,13 +9,16 @@ AllCops: - 'actionpack/lib/action_dispatch/journey/parser.rb' - 'railties/test/fixtures/tmp/**/*' -# Prefer assert_not_x over refute_x -CustomCops/RefuteNot: +Rails: + Enabled: true + +# Prefer assert_not over assert ! +Rails/AssertNot: Include: - '**/test/**/*' -# Prefer assert_not over assert ! -CustomCops/AssertNot: +# Prefer assert_not_x over refute_x +Rails/RefuteMethods: Include: - '**/test/**/*' -- cgit v1.2.3