Skip to content

Commit f5360ab

Browse files
Use Rubocop plugins, use Ruby 3.0 as minimum version everywhere
1 parent 40b1908 commit f5360ab

File tree

4 files changed

+15
-19
lines changed

4 files changed

+15
-19
lines changed

.github/workflows/test.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
- name: Set up Ruby
1616
uses: ruby/setup-ruby@v1
1717
with:
18-
ruby-version: 3.2
18+
ruby-version: 3.0
1919
bundler-cache: true
2020
rubygems: latest
2121

@@ -29,7 +29,7 @@ jobs:
2929
grape: [ '~> 2.0.0', 'head' ]
3030
grape_swagger: [ '~> 2.0.3', 'head' ]
3131
grape_entity: [ '~> 1.0.1', 'head' ]
32-
ruby: [ '3.1', '3.4', 'head' ]
32+
ruby: [ '3.0', '3.4', 'head' ]
3333
# Exclude combinations that are not supported.
3434
exclude:
3535
- { grape_swagger: '~> 2.0.3', grape: 'head' }

.rubocop.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ AllCops:
33
Exclude:
44
- vendor/**/*
55
TargetRubyVersion:
6-
2.7
6+
3.0
77

88
inherit_from: .rubocop_todo.yml
99

10-
require:
10+
plugins:
1111
- rubocop-rake
1212
- rubocop-rspec
1313

.rubocop_todo.yml

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,11 @@
11
# This configuration was generated by
22
# `rubocop --auto-gen-config`
3-
# on 2024-09-09 22:35:29 UTC using RuboCop version 1.66.1.
3+
# on 2025-05-28 16:51:29 UTC using RuboCop version 1.75.5.
44
# The point is for the user to remove these configuration records
55
# one by one as the offenses are removed from the code base.
66
# Note that changes in the inspected code, or installation of new
77
# versions of RuboCop, may require this file to be generated again.
88

9-
# Offense count: 1
10-
# Configuration parameters: Severity, Include.
11-
# Include: **/*.gemspec
12-
Gemspec/RequiredRubyVersion:
13-
Exclude:
14-
- 'grape-swagger-entity.gemspec'
15-
169
# Offense count: 3
1710
# Configuration parameters: AllowedMethods.
1811
# AllowedMethods: enums
@@ -64,7 +57,7 @@ Metrics/PerceivedComplexity:
6457
# Offense count: 5
6558
# Configuration parameters: EnforcedStyle, CheckMethodNames, CheckSymbols, AllowedIdentifiers, AllowedPatterns.
6659
# SupportedStyles: snake_case, normalcase, non_integer
67-
# AllowedIdentifiers: capture3, iso8601, rfc1123_date, rfc822, rfc2822, rfc3339, x86_64
60+
# AllowedIdentifiers: TLS1_1, TLS1_2, capture3, iso8601, rfc1123_date, rfc822, rfc2822, rfc3339, x86_64
6861
Naming/VariableNumber:
6962
Exclude:
7063
- 'spec/grape-swagger/entities/response_model_spec.rb'
@@ -102,7 +95,7 @@ RSpec/DescribeClass:
10295
RSpec/ExampleLength:
10396
Max: 187
10497

105-
# Offense count: 24
98+
# Offense count: 26
10699
RSpec/LeakyConstantDeclaration:
107100
Exclude:
108101
- 'spec/grape-swagger/entities/response_model_spec.rb'
@@ -118,14 +111,14 @@ RSpec/MultipleDescribes:
118111
RSpec/MultipleExpectations:
119112
Max: 11
120113

121-
# Offense count: 20
114+
# Offense count: 21
122115
# Configuration parameters: EnforcedStyle, IgnoreSharedExamples.
123116
# SupportedStyles: always, named_only
124117
RSpec/NamedSubject:
125118
Exclude:
126119
- 'spec/grape-swagger/entities/response_model_spec.rb'
127120

128-
# Offense count: 39
121+
# Offense count: 46
129122
# Configuration parameters: AllowedGroups.
130123
RSpec/NestedGroups:
131124
Max: 5

Gemfile

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,12 @@ group :development, :test do
3434
gem 'rake'
3535
gem 'rdoc'
3636
gem 'rspec'
37-
gem 'rubocop'
38-
gem 'rubocop-rake'
39-
gem 'rubocop-rspec'
37+
end
38+
39+
group :development do
40+
gem 'rubocop', '>= 1.72', require: false
41+
gem 'rubocop-rake', '>= 0.7', require: false
42+
gem 'rubocop-rspec', '>= 3.5.0', require: false
4043
end
4144

4245
group :test do

0 commit comments

Comments
 (0)