Skip to content

Commit b259715

Browse files
committed
RuboCop for test file
1 parent 5346a9b commit b259715

File tree

2 files changed

+18
-17
lines changed

2 files changed

+18
-17
lines changed

.rubocop.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ AllCops:
88
- 'lib/truffle/date/delta/parser.rb' # generated code
99
- 'lib/truffle/socket/mri.rb' # taken from MRI
1010
- 'lib/truffle/ffi/library.rb' # taken from FFI gem
11+
- 'src/test/ruby/types.rb' # deliberately strange code for debugging purposes
1112

1213
# Type 'Layout' (166):
1314
# Supports --auto-correct

src/test/ruby/types.rb

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -9,22 +9,22 @@
99
# Beware, RubyDebugTest use hard-coded line numbers from this file!
1010

1111
def temperature_in_city(name)
12-
cityArray = name.bytes
13-
citySum = cityArray.reduce(0, :+)
14-
weatherTemperature = citySum.modulo(36)
15-
blt = true
16-
blf = false
17-
null = nil
18-
nm1 = 1
19-
nm11 = 1.111
20-
nme = 35e45
21-
nc = 2 + 3i
22-
nr = Rational(0.3)
23-
str = "A String"
24-
symbol = :symbolic
25-
arr = [1, '2', 3.56, blt, nil, str]
26-
hash = {:a => 1, "b" => 2}
27-
nme + nm1
12+
cityArray = name.bytes
13+
citySum = cityArray.reduce(0, :+)
14+
weatherTemperature = citySum.modulo(36)
15+
blt = true
16+
blf = false
17+
null = nil
18+
nm1 = 1
19+
nm11 = 1.111
20+
nme = 35e45
21+
nc = 2 + 3i
22+
nr = Rational(0.3)
23+
str = 'A String'
24+
symbol = :symbolic
25+
arr = [1, '2', 3.56, blt, nil, str]
26+
hash = {:a => 1, 'b' => 2}
27+
nme + nm1
2828
end
2929

30-
temperature_in_city("Panama")
30+
temperature_in_city('Panama')

0 commit comments

Comments
 (0)