Skip to content

Commit f73f12b

Browse files
authored
Merge pull request #73 from maxmind/horgh/update-ruby
Test on Ruby 3.4, drop Ruby 2.7
2 parents 21cb417 + 97daf2d commit f73f12b

File tree

8 files changed

+10
-13
lines changed

8 files changed

+10
-13
lines changed

.github/workflows/rubocop.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ jobs:
1313
- uses: actions/checkout@v4
1414
- uses: ruby/setup-ruby@v1
1515
with:
16-
ruby-version: 3.3
16+
ruby-version: 3.4
1717
- run: bundle install
1818
- run: bundle exec rake -t rubocop

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,11 @@ jobs:
1515
os: [ubuntu-latest, windows-latest, macos-latest]
1616
version:
1717
[
18-
2.7,
1918
'3.0',
2019
3.1,
2120
3.2,
2221
3.3,
22+
3.4,
2323
jruby,
2424
]
2525
exclude:

.rubocop.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
require: rubocop-performance
22

33
AllCops:
4-
TargetRubyVersion: 2.7
4+
TargetRubyVersion: '3.0'
55
NewCops: enable
66

77
# Metrics are too arbitrary.

CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
## 1.3.0
44

5-
* Ruby 2.5 and 2.6 are no longer supported. If you're using one of these
6-
versions, please use version 1.2.0 of this gem.
5+
* Ruby 3.0+ is now required. If you're using Ruby 2.5, 2.6, or 2.7, please
6+
use version 1.2.0 of this gem.
77

88
## 1.2.0 (2023-11-22)
99

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ For more information see the
3535

3636
## Requirements
3737

38-
This code requires Ruby version 2.7 or higher.
38+
This code requires Ruby version 3.0 or higher.
3939

4040
## Contributing
4141

maxmind-db.gemspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ Gem::Specification.new do |s|
1919
'source_code_uri' => 'https://github.com/maxmind/MaxMind-DB-Reader-ruby',
2020
'rubygems_mfa_required' => 'true',
2121
}
22-
s.required_ruby_version = '>= 2.7.0'
22+
s.required_ruby_version = '>= 3.0'
2323

2424
s.add_development_dependency 'minitest'
2525
s.add_development_dependency 'rake'

test/test_decoder.rb

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -211,11 +211,9 @@ def test_uint128
211211
end
212212

213213
def validate_type_decoding(type, tests)
214-
values = []
215-
tests.each do |input, expected|
216-
values << check_decoding(type, input, expected)
214+
tests.map do |input, expected|
215+
check_decoding(type, input, expected)
217216
end
218-
values
219217
end
220218

221219
def check_decoding(type, input, expected, name = nil)

test/test_reader.rb

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -316,10 +316,9 @@ def test_metadata_unknown_attribute
316316
reader = MaxMind::DB.new(
317317
'test/data/test-data/MaxMind-DB-test-decoder.mmdb'
318318
)
319-
e = assert_raises NoMethodError do
319+
assert_raises NoMethodError do
320320
reader.metadata.what
321321
end
322-
assert(e.message.include?('undefined method `what\''))
323322
reader.close
324323
end
325324

0 commit comments

Comments
 (0)