gitlab-styles 4.2.0 → 5.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. checksums.yaml +4 -4
  2. data/.editorconfig +18 -0
  3. data/.gitlab-ci.yml +5 -16
  4. data/.gitlab/merge_request_templates/New Static Analysis Check.md +21 -0
  5. data/.gitlab/merge_request_templates/Release.md +4 -4
  6. data/.rubocop.yml +3 -1
  7. data/Gemfile +2 -2
  8. data/gitlab-styles.gemspec +6 -5
  9. data/lib/gitlab/styles/rubocop.rb +3 -14
  10. data/lib/gitlab/styles/rubocop/cop/active_record_dependent.rb +1 -1
  11. data/lib/gitlab/styles/rubocop/cop/code_reuse/active_record.rb +131 -0
  12. data/lib/gitlab/styles/rubocop/cop/custom_error_class.rb +6 -3
  13. data/lib/gitlab/styles/rubocop/cop/gem_fetcher.rb +1 -1
  14. data/lib/gitlab/styles/rubocop/cop/line_break_after_guard_clauses.rb +1 -1
  15. data/lib/gitlab/styles/rubocop/cop/line_break_around_conditional_block.rb +132 -0
  16. data/lib/gitlab/styles/rubocop/cop/migration/update_large_table.rb +1 -1
  17. data/lib/gitlab/styles/rubocop/cop/polymorphic_associations.rb +1 -1
  18. data/lib/gitlab/styles/rubocop/cop/rspec/base.rb +18 -0
  19. data/lib/gitlab/styles/rubocop/cop/rspec/empty_line_after_let_block.rb +65 -0
  20. data/lib/gitlab/styles/rubocop/cop/rspec/empty_line_after_shared_example.rb +6 -6
  21. data/lib/gitlab/styles/rubocop/cop/rspec/example_starting_character.rb +124 -0
  22. data/lib/gitlab/styles/rubocop/cop/rspec/have_link_parameters.rb +10 -5
  23. data/lib/gitlab/styles/rubocop/cop/rspec/single_line_hook.rb +3 -2
  24. data/lib/gitlab/styles/rubocop/cop/rspec/verbose_include_metadata.rb +10 -13
  25. data/lib/gitlab/styles/rubocop/model_helpers.rb +1 -1
  26. data/lib/gitlab/styles/rubocop/rspec/helpers.rb +17 -0
  27. data/lib/gitlab/styles/version.rb +1 -1
  28. data/rubocop-all.yml +1 -0
  29. data/rubocop-bundler.yml +1 -0
  30. data/rubocop-code_reuse.yml +24 -0
  31. data/rubocop-default.yml +1 -0
  32. data/rubocop-gemspec.yml +1 -0
  33. data/rubocop-layout.yml +6 -0
  34. data/rubocop-lint.yml +63 -5
  35. data/rubocop-metrics.yml +1 -0
  36. data/rubocop-migrations.yml +1 -0
  37. data/rubocop-naming.yml +1 -0
  38. data/rubocop-performance.yml +48 -0
  39. data/rubocop-rails.yml +79 -0
  40. data/rubocop-rspec.yml +10 -0
  41. data/rubocop-security.yml +1 -0
  42. data/rubocop-style.yml +91 -1
  43. metadata +23 -15
  44. data/.rubocop_todo.yml +0 -7
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gitlab-styles
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.2.0
4
+ version: 5.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - GitLab
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-05-19 00:00:00.000000000 Z
11
+ date: 2020-12-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rubocop
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 0.82.0
19
+ version: 0.89.1
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 0.82.0
26
+ version: 0.89.1
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rubocop-gitlab-security
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -44,56 +44,56 @@ dependencies:
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: 1.5.2
47
+ version: 1.8.1
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: 1.5.2
54
+ version: 1.8.1
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rubocop-rails
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: '2.5'
61
+ version: '2.8'
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: '2.5'
68
+ version: '2.8'
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: rubocop-rspec
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
73
  - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: '1.36'
75
+ version: '1.44'
76
76
  type: :runtime
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
80
  - - "~>"
81
81
  - !ruby/object:Gem::Version
82
- version: '1.36'
82
+ version: '1.44'
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: bundler
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
87
  - - "~>"
88
88
  - !ruby/object:Gem::Version
89
- version: '1.16'
89
+ version: '2.1'
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
94
  - - "~>"
95
95
  - !ruby/object:Gem::Version
96
- version: '1.16'
96
+ version: '2.1'
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: rake
99
99
  requirement: !ruby/object:Gem::Requirement
@@ -129,12 +129,13 @@ executables: []
129
129
  extensions: []
130
130
  extra_rdoc_files: []
131
131
  files:
132
+ - ".editorconfig"
132
133
  - ".gitignore"
133
134
  - ".gitlab-ci.yml"
135
+ - ".gitlab/merge_request_templates/New Static Analysis Check.md"
134
136
  - ".gitlab/merge_request_templates/Release.md"
135
137
  - ".rspec"
136
138
  - ".rubocop.yml"
137
- - ".rubocop_todo.yml"
138
139
  - CODE_OF_CONDUCT.md
139
140
  - CONTRIBUTING.md
140
141
  - Gemfile
@@ -148,23 +149,30 @@ files:
148
149
  - lib/gitlab/styles/rubocop.rb
149
150
  - lib/gitlab/styles/rubocop/cop/active_record_dependent.rb
150
151
  - lib/gitlab/styles/rubocop/cop/active_record_serialize.rb
152
+ - lib/gitlab/styles/rubocop/cop/code_reuse/active_record.rb
151
153
  - lib/gitlab/styles/rubocop/cop/custom_error_class.rb
152
154
  - lib/gitlab/styles/rubocop/cop/gem_fetcher.rb
153
155
  - lib/gitlab/styles/rubocop/cop/in_batches.rb
154
156
  - lib/gitlab/styles/rubocop/cop/line_break_after_guard_clauses.rb
157
+ - lib/gitlab/styles/rubocop/cop/line_break_around_conditional_block.rb
155
158
  - lib/gitlab/styles/rubocop/cop/migration/update_large_table.rb
156
159
  - lib/gitlab/styles/rubocop/cop/polymorphic_associations.rb
157
160
  - lib/gitlab/styles/rubocop/cop/redirect_with_status.rb
161
+ - lib/gitlab/styles/rubocop/cop/rspec/base.rb
162
+ - lib/gitlab/styles/rubocop/cop/rspec/empty_line_after_let_block.rb
158
163
  - lib/gitlab/styles/rubocop/cop/rspec/empty_line_after_shared_example.rb
164
+ - lib/gitlab/styles/rubocop/cop/rspec/example_starting_character.rb
159
165
  - lib/gitlab/styles/rubocop/cop/rspec/have_link_parameters.rb
160
166
  - lib/gitlab/styles/rubocop/cop/rspec/single_line_hook.rb
161
167
  - lib/gitlab/styles/rubocop/cop/rspec/verbose_include_metadata.rb
162
168
  - lib/gitlab/styles/rubocop/cop/without_reactive_cache.rb
163
169
  - lib/gitlab/styles/rubocop/migration_helpers.rb
164
170
  - lib/gitlab/styles/rubocop/model_helpers.rb
171
+ - lib/gitlab/styles/rubocop/rspec/helpers.rb
165
172
  - lib/gitlab/styles/version.rb
166
173
  - rubocop-all.yml
167
174
  - rubocop-bundler.yml
175
+ - rubocop-code_reuse.yml
168
176
  - rubocop-default.yml
169
177
  - rubocop-gemspec.yml
170
178
  - rubocop-layout.yml
@@ -189,14 +197,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
189
197
  requirements:
190
198
  - - ">="
191
199
  - !ruby/object:Gem::Version
192
- version: '0'
200
+ version: '2.6'
193
201
  required_rubygems_version: !ruby/object:Gem::Requirement
194
202
  requirements:
195
203
  - - ">="
196
204
  - !ruby/object:Gem::Version
197
205
  version: '0'
198
206
  requirements: []
199
- rubygems_version: 3.1.3
207
+ rubygems_version: 3.1.4
200
208
  signing_key:
201
209
  specification_version: 4
202
210
  summary: GitLab style guides and shared style configs.
@@ -1,7 +0,0 @@
1
- # This configuration was generated by
2
- # `rubocop --auto-gen-config`
3
- # on 2017-11-03 15:49:59 +0100 using RuboCop version 0.51.0.
4
- # The point is for the user to remove these configuration records
5
- # one by one as the offenses are removed from the code base.
6
- # Note that changes in the inspected code, or installation of new
7
- # versions of RuboCop, may require this file to be generated again.