Skip to content

Commit 78450cb

Browse files
authored
Merge pull request #70 from maxmind/horgh/ruby-version
Test on Ruby 3.1
2 parents 4db9203 + 58647cd commit 78450cb

File tree

5 files changed

+8
-7
lines changed

5 files changed

+8
-7
lines changed

.github/workflows/rubocop.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,6 @@ jobs:
77
- uses: actions/checkout@v2
88
- uses: ruby/setup-ruby@v1
99
with:
10-
ruby-version: '3.0'
10+
ruby-version: 3.1
1111
- run: bundle install
1212
- run: bundle exec rake -t rubocop

.github/workflows/test.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ jobs:
1313
2.6,
1414
2.7,
1515
'3.0',
16+
3.1,
1617
jruby,
1718
]
1819
exclude:

spec/model/factors_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
describe Minfraud::Model::Factors do
77
describe '#initialize' do
88
it 'creates a fully populated object' do
9-
buf = File.open('spec/fixtures/files/factors-response1.json').read
9+
buf = File.read('spec/fixtures/files/factors-response1.json')
1010
record = JSON.parse(buf)
1111

1212
m = Minfraud::Model::Factors.new(record, ['en'])

spec/model/insights_spec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
describe Minfraud::Model::Insights do
77
describe '#initialize' do
88
it 'creates a fully populated object' do
9-
buf = File.open('spec/fixtures/files/insights-response1.json').read
9+
buf = File.read('spec/fixtures/files/insights-response1.json')
1010
record = JSON.parse(buf)
1111

1212
m = Minfraud::Model::Insights.new(record, ['en'])
@@ -135,7 +135,7 @@
135135
end
136136

137137
it 'creates a populated object missing some fields' do
138-
buf = File.open('spec/fixtures/files/insights-response2.json').read
138+
buf = File.read('spec/fixtures/files/insights-response2.json')
139139
record = JSON.parse(buf)
140140

141141
m = Minfraud::Model::Insights.new(record, ['en'])
@@ -192,7 +192,7 @@
192192
end
193193

194194
it 'creates an object when the response lacks many fields' do
195-
buf = File.open('spec/fixtures/files/insights-response3.json').read
195+
buf = File.read('spec/fixtures/files/insights-response3.json')
196196
record = JSON.parse(buf)
197197

198198
m = Minfraud::Model::Insights.new(record, ['en'])

spec/model/score_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
describe Minfraud::Model::Score do
77
describe '#initialize' do
88
it 'creates a fully populated object' do
9-
buf = File.open('spec/fixtures/files/score-response1.json').read
9+
buf = File.read('spec/fixtures/files/score-response1.json')
1010
record = JSON.parse(buf)
1111

1212
score = Minfraud::Model::Score.new(record, ['en'])
@@ -30,7 +30,7 @@
3030
end
3131

3232
it 'creates a minimally populated object' do
33-
buf = File.open('spec/fixtures/files/score-response2.json').read
33+
buf = File.read('spec/fixtures/files/score-response2.json')
3434
record = JSON.parse(buf)
3535

3636
score = Minfraud::Model::Score.new(record, ['en'])

0 commit comments

Comments
 (0)