Skip to content

Commit

Permalink
Bump ruby requirements to >= 3.0, bump self versions
Browse files Browse the repository at this point in the history
  • Loading branch information
godric committed Feb 19, 2024
1 parent 262c732 commit 6dc6dd7
Show file tree
Hide file tree
Showing 10 changed files with 19 additions and 19 deletions.
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ jobs:

test-getaround-rubocop:
docker:
- image: cimg/ruby:2.7.4
- image: cimg/ruby:3.0.6
working_directory: /tmp/build/getaround-rubocop
steps:
- checkout:
Expand All @@ -22,7 +22,7 @@ jobs:
test-getaround_utils:
docker:
- image: cimg/ruby:2.7.4
- image: cimg/ruby:3.0.6
working_directory: /tmp/build/getaround_utils
steps:
- checkout:
Expand Down
2 changes: 1 addition & 1 deletion getaround-rubocop/.ruby-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
ruby-2.7.4
ruby-3.0.6
4 changes: 2 additions & 2 deletions getaround-rubocop/Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
getaround-rubocop (0.2.9)
getaround-rubocop (0.2.10)
relaxed-rubocop (= 2.5)
rubocop (= 1.55.1)
rubocop-performance (= 1.18.0)
Expand Down Expand Up @@ -73,4 +73,4 @@ DEPENDENCIES
getaround-rubocop!

BUNDLED WITH
2.3.16
2.4.22
4 changes: 2 additions & 2 deletions getaround-rubocop/getaround-rubocop.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@

Gem::Specification.new do |gem|
gem.name = "getaround-rubocop"
gem.version = '0.2.9'
gem.version = '0.2.10'
gem.summary = "Backend configuration files"
gem.description = "Shared base configuration for Getaround Backend Applications."
gem.authors = ["Drivy", "Laurent Humez"]
gem.email = ["[email protected]"]
gem.homepage = "https://github.com/drivy"
gem.license = "MIT"
gem.required_ruby_version = '>= 2.7'
gem.required_ruby_version = '>= 3.0'

gem.files = Dir.chdir(File.expand_path(__dir__)) do
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(spec)/}) }
Expand Down
2 changes: 1 addition & 1 deletion getaround_utils/.ruby-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
ruby-2.7.4
ruby-3.0.6
4 changes: 2 additions & 2 deletions getaround_utils/Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
getaround_utils (0.2.28)
getaround_utils (0.2.30)
rack (~> 2.0)

GEM
Expand Down Expand Up @@ -264,4 +264,4 @@ DEPENDENCIES
webmock (~> 3.7)

BUNDLED WITH
2.3.16
2.4.22
2 changes: 1 addition & 1 deletion getaround_utils/getaround_utils.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Gem::Specification.new do |gem|
gem.email = ['[email protected]']
gem.homepage = 'https://github.com/drivy'
gem.license = 'MIT'
gem.required_ruby_version = '>= 2.7'
gem.required_ruby_version = '>= 3.0'

gem.files = Dir.chdir(File.expand_path(__dir__)) do
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(spec)/}) }
Expand Down
2 changes: 1 addition & 1 deletion getaround_utils/lib/getaround_utils/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module GetaroundUtils
VERSION = '0.2.29'
VERSION = '0.2.30'
end
4 changes: 2 additions & 2 deletions getaround_utils/spec/getaround_utils/mixins/loggable_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -184,8 +184,8 @@ def append_infos_to_loggable(payload)
stub_const('BaseClass', Class.new{
include GetaroundUtils::Mixins::Loggable

def use_monitorable(*args)
monitorable_log(*args)
def use_monitorable(*args, **kwargs)
monitorable_log(*args, **kwargs)
end
})
end
Expand Down
10 changes: 5 additions & 5 deletions getaround_utils/spec/getaround_utils/railties/ougai_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@

it 'forwards simple log params to the formatter' do
expect(Rails.application.config.ougai_logger.formatter).to receive(:call)
.with("ERROR", kind_of(Time), nil, msg: 'message')
.with("ERROR", kind_of(Time), nil, { msg: 'message' })
Rails.logger.error('message')
end

it 'forwards structured log params to the formatter' do
expect(Rails.application.config.ougai_logger.formatter).to receive(:call)
.with("ERROR", kind_of(Time), nil, key: :value, msg: 'message')
.with("ERROR", kind_of(Time), nil, { key: :value, msg: 'message' })
Rails.logger.error('message', key: :value)
end
end
Expand Down Expand Up @@ -59,7 +59,7 @@ def log_message; logger.warn('message', key: :value); end
allow(RequestStore).to receive(:store)
.and_return(ougai: { http: { request_id: 'test' } })
expect(Rails.application.config.ougai_logger.formatter).to receive(:call)
.with("WARN", kind_of(Time), nil, key: :value, msg: 'message', http: { request_id: 'test' })
.with("WARN", kind_of(Time), nil, { key: :value, msg: 'message', http: { request_id: 'test' } })
controller.log_message
end
end
Expand All @@ -77,7 +77,7 @@ def log_message; logger.warn('message', key: :value); end
base_logger = OugaiRailsLogger.new($stdout)
logger = ActiveSupport::TaggedLogging.new(base_logger)
expect(logger.formatter).to receive(:_call)
.with('WARN', kind_of(Time), nil, msg: "message", tags: ["tag"])
.with('WARN', kind_of(Time), nil, { msg: "message", tags: ["tag"] })
logger.tagged('tag') { logger.warn('message') }
end
end
Expand All @@ -104,7 +104,7 @@ def perform

it 'includes the extra data from the sidekiq context' do
expect(Rails.application.config.ougai_logger.formatter).to receive(:call)
.with("WARN", kind_of(Time), nil, key: :value, msg: 'message', sidekiq: { job_id: 'test' })
.with("WARN", kind_of(Time), nil, { key: :value, msg: 'message', sidekiq: { job_id: 'test' } })
worker.new.perform
end
end
Expand Down

0 comments on commit 6dc6dd7

Please sign in to comment.