Skip to content

Commit 33408b6

Browse files
committed
Update gems + adapt to latest rubocop styles
gemwork v0.7.14 brings in new rubocop styles / adjustments, that we must catch up with here.
1 parent ebfe361 commit 33408b6

File tree

9 files changed

+67
-57
lines changed

9 files changed

+67
-57
lines changed

.rubocop.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Load Rubocop plugins.
2-
require:
2+
plugins:
33
- rubocop-rake
44
- rubocop-minitest
55
- rubocop-performance

Gemfile.lock

Lines changed: 43 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -7,18 +7,18 @@ GEM
77
remote: https://rubygems.org/
88
specs:
99
ansi (1.5.0)
10-
ast (2.4.2)
10+
ast (2.4.3)
1111
benchmark-ips (2.14.0)
1212
bigdecimal (3.1.9)
1313
builder (3.3.0)
14-
concurrent-ruby (1.3.4)
14+
concurrent-ruby (1.3.5)
1515
date (3.4.1)
1616
debug (1.10.0)
1717
irb (~> 1.10)
1818
reline (>= 0.3.8)
1919
docile (1.4.1)
20-
dry-configurable (1.2.0)
21-
dry-core (~> 1.0, < 2)
20+
dry-configurable (1.3.0)
21+
dry-core (~> 1.1)
2222
zeitwerk (~> 2.6)
2323
dry-core (1.1.0)
2424
concurrent-ruby (~> 1.0)
@@ -39,14 +39,14 @@ GEM
3939
dry-logic (>= 1.4, < 2)
4040
dry-types (>= 1.7, < 2)
4141
zeitwerk (~> 2.6)
42-
dry-types (1.7.2)
42+
dry-types (1.8.2)
4343
bigdecimal (~> 3.0)
4444
concurrent-ruby (~> 1.0)
4545
dry-core (~> 1.0)
4646
dry-inflector (~> 1.0)
4747
dry-logic (~> 1.4)
4848
zeitwerk (~> 2.6)
49-
gemwork (0.7.4)
49+
gemwork (0.7.14)
5050
debug
5151
irb
5252
minitest
@@ -60,13 +60,15 @@ GEM
6060
simplecov
6161
yard
6262
io-console (0.8.0)
63-
irb (1.14.3)
63+
irb (1.15.1)
64+
pp (>= 0.6.0)
6465
rdoc (>= 4.0.0)
6566
reline (>= 0.4.2)
66-
json (2.9.1)
67-
language_server-protocol (3.17.0.3)
68-
logger (1.6.4)
69-
minitest (5.25.4)
67+
json (2.10.2)
68+
language_server-protocol (3.17.0.4)
69+
lint_roller (1.1.0)
70+
logger (1.6.6)
71+
minitest (5.25.5)
7072
minitest-reporters (1.7.1)
7173
ansi
7274
builder
@@ -75,59 +77,67 @@ GEM
7577
much-stub (0.1.10)
7678
object_identifier (0.10.0)
7779
parallel (1.26.3)
78-
parser (3.3.6.0)
80+
parser (3.3.7.2)
7981
ast (~> 2.4.1)
8082
racc
81-
psych (5.2.2)
83+
pp (0.6.2)
84+
prettyprint
85+
prettyprint (0.2.0)
86+
psych (5.2.3)
8287
date
8388
stringio
8489
racc (1.8.1)
8590
rainbow (3.1.1)
8691
rake (13.2.1)
87-
rdoc (6.10.0)
92+
rdoc (6.12.0)
8893
psych (>= 4.0.0)
89-
reek (6.3.0)
94+
reek (6.4.0)
9095
dry-schema (~> 1.13.0)
96+
logger (~> 1.6)
9197
parser (~> 3.3.0)
9298
rainbow (>= 2.0, < 4.0)
9399
rexml (~> 3.1)
94100
regexp_parser (2.10.0)
95101
reline (0.6.0)
96102
io-console (~> 0.5)
97-
rexml (3.4.0)
98-
rubocop (1.69.2)
103+
rexml (3.4.1)
104+
rubocop (1.74.0)
99105
json (~> 2.3)
100-
language_server-protocol (>= 3.17.0)
106+
language_server-protocol (~> 3.17.0.2)
107+
lint_roller (~> 1.1.0)
101108
parallel (~> 1.10)
102109
parser (>= 3.3.0.2)
103110
rainbow (>= 2.2.2, < 4.0)
104111
regexp_parser (>= 2.9.3, < 3.0)
105-
rubocop-ast (>= 1.36.2, < 2.0)
112+
rubocop-ast (>= 1.38.0, < 2.0)
106113
ruby-progressbar (~> 1.7)
107114
unicode-display_width (>= 2.4.0, < 4.0)
108-
rubocop-ast (1.37.0)
109-
parser (>= 3.3.1.0)
110-
rubocop-minitest (0.36.0)
111-
rubocop (>= 1.61, < 2.0)
112-
rubocop-ast (>= 1.31.1, < 2.0)
113-
rubocop-performance (1.23.1)
114-
rubocop (>= 1.48.1, < 2.0)
115-
rubocop-ast (>= 1.31.1, < 2.0)
116-
rubocop-rake (0.6.0)
117-
rubocop (~> 1.0)
115+
rubocop-ast (1.41.0)
116+
parser (>= 3.3.7.2)
117+
rubocop-minitest (0.37.1)
118+
lint_roller (~> 1.1)
119+
rubocop (>= 1.72.1, < 2.0)
120+
rubocop-ast (>= 1.38.0, < 2.0)
121+
rubocop-performance (1.24.0)
122+
lint_roller (~> 1.1)
123+
rubocop (>= 1.72.1, < 2.0)
124+
rubocop-ast (>= 1.38.0, < 2.0)
125+
rubocop-rake (0.7.1)
126+
lint_roller (~> 1.1)
127+
rubocop (>= 1.72.1)
118128
ruby-progressbar (1.13.0)
119129
simplecov (0.22.0)
120130
docile (~> 1.1)
121131
simplecov-html (~> 0.11)
122132
simplecov_json_formatter (~> 0.1)
123133
simplecov-html (0.13.1)
124134
simplecov_json_formatter (0.1.4)
125-
stringio (3.1.2)
126-
unicode-display_width (3.1.3)
135+
stringio (3.1.5)
136+
unicode-display_width (3.1.4)
127137
unicode-emoji (~> 4.0, >= 4.0.4)
128138
unicode-emoji (4.0.4)
129139
yard (0.9.37)
130-
zeitwerk (2.7.1)
140+
zeitwerk (2.7.2)
131141

132142
PLATFORMS
133143
arm64-darwin-23
@@ -142,4 +152,4 @@ DEPENDENCIES
142152
rake
143153

144154
BUNDLED WITH
145-
2.6.2
155+
2.6.6

lib/object_inspector.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ def initialize
5151

5252
def formatter_class=(value)
5353
unless value.is_a?(Class)
54-
raise TypeError, "Formatter must be a Class constant"
54+
raise(TypeError, "Formatter must be a Class constant")
5555
end
5656

5757
@formatter_class = value

lib/object_inspector/formatters/base_formatter.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ def initialize(inspector)
1616
#
1717
# @return [String]
1818
def call
19-
raise NotImplementedError
19+
raise(NotImplementedError)
2020
end
2121

2222
# Delegates to {Inspector#wrapped_object_inspection_result}.

rakelib/bump.rake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ def replace_in_file(path, replacements)
4848
original_file_contents = file_contents.dup
4949

5050
replacements.each do |regex, text|
51-
raise "Can't find #{regex} in #{path}" unless regex.match?(file_contents)
51+
raise("Can't find #{regex} in #{path}") unless regex.match?(file_contents)
5252

5353
file_contents.gsub!(regex) do |match|
5454
match[regex, 1] = text

rakelib/gemwork.rake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ spec = Gem::Specification.find_by_name("gemwork")
44

55
# Load additional tasks defined by Gemwork.
66
Dir.glob(
7-
Pathname.new(spec.gem_dir).
8-
join("lib", "tasks", "{util,rubocop,reek,test,prettier}.rake")) do |task|
7+
Pathname.new(spec.gem_dir)
8+
.join("lib/tasks", "{util,test,rubocop,reek,prettier}.rake")) do |task|
99
load(task)
1010
end
1111

test/object_inspector/inspector_test.rb

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -175,8 +175,8 @@ class ObjectInspector::InspectorTest < Minitest::Spec
175175
subject { klazz.new(wrapper_for_full_test_object1) }
176176

177177
it "returns Object#to_model#inspect" do
178-
_(subject.wrapped_object_inspection_result).
179-
must_equal("<Identification[id:1](FLAG1) Info: 1 :: Name: 1>")
178+
_(subject.wrapped_object_inspection_result)
179+
.must_equal("<Identification[id:1](FLAG1) Info: 1 :: Name: 1>")
180180
end
181181
end
182182

@@ -195,21 +195,21 @@ class ObjectInspector::InspectorTest < Minitest::Spec
195195
context "GIVEN #value is a Symbol" do
196196
it "returns Object#<value>, GIVEN Object responds to #value" do
197197
_(
198-
subject.__send__(:evaluate_passed_in_value, :simple_test_method)).
199-
must_equal("TEST_RESULT")
198+
subject.__send__(:evaluate_passed_in_value, :simple_test_method))
199+
.must_equal("TEST_RESULT")
200200
end
201201

202202
it "returns #value, GIVEN Object does not respond to #value" do
203-
_(subject.__send__(:evaluate_passed_in_value, :unknown_method1)).
204-
must_equal(:unknown_method1)
203+
_(subject.__send__(:evaluate_passed_in_value, :unknown_method1))
204+
.must_equal(:unknown_method1)
205205
end
206206
end
207207

208208
context "GIVEN #value is not a Symbol" do
209209
it "returns #value" do
210210
_(
211-
subject.__send__(:evaluate_passed_in_value, "simple_test_method")).
212-
must_equal("simple_test_method")
211+
subject.__send__(:evaluate_passed_in_value, "simple_test_method"))
212+
.must_equal("simple_test_method")
213213
end
214214
end
215215
end

test/object_inspector/scope_test.rb

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ class SimpleTestObject # rubocop:disable Lint/EmptyClass
7676
subject { self_scope }
7777

7878
it "raises NoMethodError" do
79-
_(-> { subject.unknown_method }).must_raise NoMethodError
79+
_(-> { subject.unknown_method }).must_raise(NoMethodError)
8080
end
8181
end
8282

@@ -177,8 +177,8 @@ class SimpleTestObject # rubocop:disable Lint/EmptyClass
177177
end
178178

179179
it "returns nil, GIVEN an array of `nil`s with nested arrays of `nil`s" do
180-
_(subject.join_name([nil, nil, [nil, nil, [nil, nil]]])).
181-
must_be_nil
180+
_(subject.join_name([nil, nil, [nil, nil, [nil, nil]]]))
181+
.must_be_nil
182182
end
183183
end
184184

@@ -206,8 +206,8 @@ class SimpleTestObject # rubocop:disable Lint/EmptyClass
206206
end
207207

208208
it "returns nil, GIVEN an array of `nil`s with nested arrays of `nil`s" do
209-
_(subject.join_flags([nil, nil, [nil, nil, [nil, nil]]])).
210-
must_be_nil
209+
_(subject.join_flags([nil, nil, [nil, nil, [nil, nil]]]))
210+
.must_be_nil
211211
end
212212
end
213213

@@ -235,8 +235,8 @@ class SimpleTestObject # rubocop:disable Lint/EmptyClass
235235
end
236236

237237
it "returns nil, GIVEN an array of `nil`s with nested arrays of `nil`s" do
238-
_(subject.join_issues([nil, nil, [nil, nil, [nil, nil]]])).
239-
must_be_nil
238+
_(subject.join_issues([nil, nil, [nil, nil, [nil, nil]]]))
239+
.must_be_nil
240240
end
241241
end
242242

@@ -264,8 +264,8 @@ class SimpleTestObject # rubocop:disable Lint/EmptyClass
264264
end
265265

266266
it "returns nil, GIVEN an array of `nil`s with nested arrays of `nil`s" do
267-
_(subject.join_info([nil, nil, [nil, nil, [nil, nil]]])).
268-
must_be_nil
267+
_(subject.join_info([nil, nil, [nil, nil, [nil, nil]]]))
268+
.must_be_nil
269269
end
270270
end
271271
end

test/test_helper.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
require "gemwork/test/support/simplecov"
44

5-
$LOAD_PATH.unshift File.expand_path("../lib", __dir__)
5+
$LOAD_PATH.unshift(File.expand_path("../lib", __dir__))
66
require "object_inspector"
77

88
require "minitest/autorun"

0 commit comments

Comments
 (0)