Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ jobs:
build:
strategy:
matrix:
version: ["ruby:3.4", "ruby:3.3", "ruby:3.2"]
version: ["ruby:4.0", "ruby:3.4", "ruby:3.3"]
runs-on: ubuntu-latest
container: ${{ matrix.version }}
steps:
Expand Down
2 changes: 1 addition & 1 deletion .rubocop.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
AllCops:
NewCops: enable
SuggestExtensions: false
TargetRubyVersion: 3.1
TargetRubyVersion: 3.2
Layout/LineLength:
Enabled: 100
Metrics/BlockLength:
Expand Down
2 changes: 1 addition & 1 deletion .ruby-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.4.4
4.0.1
3 changes: 3 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,7 @@ gem 'webmock'
# Used as a web server for integration testing actual HTTP requests.
gem 'webrick'

# Used to test logging.
gem 'logger'

gemspec
3 changes: 1 addition & 2 deletions lib/reynard/request_context.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ class Reynard
:operation,
:headers,
:params,
:body,
keyword_init: true
:body
) do
def verb
operation&.verb
Expand Down
4 changes: 2 additions & 2 deletions lib/reynard/specification.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ def dig(*path)
# specification.find_each(type: 'object') {}
#
# Please don't use this in a hot paths in production, primarily meant for testing and tooling.
def find_each(type:, &block)
Finder.new(specification: self, query: Query.new(type:)).find_each(&block)
def find_each(type:, &)
Finder.new(specification: self, query: Query.new(type:)).find_each(&)
end

def servers
Expand Down
2 changes: 1 addition & 1 deletion reynard.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Gem::Specification.new do |spec|
]
spec.require_paths = ['lib']

spec.required_ruby_version = '> 3.1'
spec.required_ruby_version = '> 3.2'

spec.add_dependency 'multi_json'
spec.add_dependency 'net-http-persistent'
Expand Down
4 changes: 2 additions & 2 deletions test/reynard/object_builder_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ def setup
end

class WeirdObjectBuilderTest < Reynard::Test
Response = Struct.new(:body, keyword_init: true)
Response = Struct.new(:body)

def setup
@specification = Specification.new(filename: fixture_file('openapi/weird.yml'))
Expand Down Expand Up @@ -307,7 +307,7 @@ def setup
end

class PolymorphicBuilderTest < Reynard::Test
Response = Struct.new(:body, keyword_init: true)
Response = Struct.new(:body)

def setup
@specification = Specification.new(filename: fixture_file('openapi/polymorphic.yml'))
Expand Down
2 changes: 1 addition & 1 deletion test/support/simple_service.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
require 'webrick'

class SimpleService
Options = Struct.new(:port, keyword_init: true)
Options = Struct.new(:port)

class Servlet < WEBrick::HTTPServlet::AbstractServlet
def initialize(*)
Expand Down