carwow_rubocop 4.0.1 → 4.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a298086f7e65b0263cc91fe3c8d074132c26d85080f7d6005d9ff93be25b5d4f
4
- data.tar.gz: f4b3524c0cb7e68ada8939cb9f7e62cfc2a1eab9c7dd48e7d2934038b167c78d
3
+ metadata.gz: c9e7c523fde37bcd34c81d97c5e5469dcdd54847c49037305202401cda4795b6
4
+ data.tar.gz: 59126df5d4eebbb7f0924396a95dd5ecd5cf9ae405d6e214dba606f1abf349b0
5
5
  SHA512:
6
- metadata.gz: 8479fd94ca36b4f1afa7f5628dea506e6a51fbd28200b15e6f5d04328dea4bf451de345989a10572bb3e137d960e251e160a6a04702aa2b833cbb00ee1e83009
7
- data.tar.gz: 027405a2b9112e32bc4e87977b5ba87289ce57fd2b25cb7edcb11ebf2c9b8dd50bc512a3b2989201fb89c17f09045acb66a838dab09abc03e27c12e9ef596c71
6
+ metadata.gz: '007331498b901c890b99c599d8a124fbf520527eb87cd5386681ac964cba04ad8eb8aa6cc10d2886e7a8f2dba1a746a7545a90af0996977857a99ef020b1b9e7'
7
+ data.tar.gz: 3bb9f8592367f4e95a7c8e3a5dbbf36b75ed909fcd2a7855265478b56d65192b27a48604b64980811fef68eda54d08a8def62b2133381adf3873a9be0304192f
data/.circleci/config.yml CHANGED
@@ -62,12 +62,3 @@ workflows:
62
62
 
63
63
  - lint_ruby:
64
64
  requires: [carwow/start]
65
-
66
- - publish_gem:
67
- context: org-global
68
- requires:
69
- - tests
70
- - lint_ruby
71
- filters:
72
- branches:
73
- only: [master]
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- carwow_rubocop (4.0.1)
4
+ carwow_rubocop (4.0.2)
5
5
  rubocop (>= 0.93)
6
6
  rubocop-performance
7
7
  rubocop-rspec
@@ -1,5 +1,5 @@
1
1
  module RuboCop
2
2
  module Carwow
3
- VERSION = '4.0.1'.freeze
3
+ VERSION = '4.0.2'.freeze
4
4
  end
5
5
  end
@@ -55,7 +55,7 @@ module RuboCop
55
55
  def on_class(node)
56
56
  return add_global_offense(NOT_CONFIGURED) if missing_config?
57
57
 
58
- return if any_ancestor_allowed?(node)
58
+ return if any_class_in_the_file_allowed?(node)
59
59
  return if defining_allowed_job?(*node)
60
60
 
61
61
  register_offenses(node)
@@ -63,8 +63,11 @@ module RuboCop
63
63
 
64
64
  private
65
65
 
66
- def any_ancestor_allowed?(class_node)
66
+ def any_class_in_the_file_allowed?(class_node)
67
67
  root_node = class_node.root? ? class_node : class_node.ancestors.last
68
+
69
+ return true if root_node.class_type? && allowed?(super_class(*root_node))
70
+
68
71
  root_node.each_descendant(:class).any? do |node|
69
72
  allowed?(super_class(*node))
70
73
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: carwow_rubocop
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.1
4
+ version: 4.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - carwow Developers
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-11-09 00:00:00.000000000 Z
11
+ date: 2021-11-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -168,7 +168,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
168
168
  - !ruby/object:Gem::Version
169
169
  version: '0'
170
170
  requirements: []
171
- rubygems_version: 3.1.4
171
+ rubygems_version: 3.2.31
172
172
  signing_key:
173
173
  specification_version: 4
174
174
  summary: carwow's rubocop configuration