Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restore ruby 2.5 support #19

Closed
Closed
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
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
name: build (${{ matrix.ruby }} / ${{ matrix.os }})
strategy:
matrix:
ruby: [ '3.0', 2.7, 2.6, head ]
ruby: [ '3.0', 2.7, 2.6, 2.5, head ]
os: [ ubuntu-latest, macos-latest ]
runs-on: ${{ matrix.os }}
steps:
Expand All @@ -21,4 +21,4 @@ jobs:
gem install bundler --no-document
bundle install
- name: Run test
run: rake test
run: bundle exec rake test
6 changes: 3 additions & 3 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ GEM
net-protocol (0.1.0)
io-wait
timeout
power_assert (1.1.5)
power_assert (2.0.0)
rake (13.0.1)
test-unit (3.3.5)
test-unit (3.4.0)
power_assert
timeout (0.1.1)
uri (0.10.1)
Expand All @@ -30,4 +30,4 @@ DEPENDENCIES
webrick

BUNDLED WITH
2.1.4
2.2.15
2 changes: 1 addition & 1 deletion net-http.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Gem::Specification.new do |spec|
spec.summary = %q{HTTP client api for Ruby.}
spec.description = %q{HTTP client api for Ruby.}
spec.homepage = "https://github.com/ruby/net-http"
spec.required_ruby_version = Gem::Requirement.new(">= 2.6.0")
spec.required_ruby_version = Gem::Requirement.new(">= 2.5.0")
spec.licenses = ["Ruby", "BSD-2-Clause"]

spec.metadata["homepage_uri"] = spec.homepage
Expand Down
4 changes: 2 additions & 2 deletions test/net/http/test_https.rb
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def test_get
assert_equal($test_net_http_data, res.body)
}
# TODO: OpenSSL 1.1.1h seems to yield only SERVER_CERT; need to check the incompatibility
certs.zip([CA_CERT, SERVER_CERT][-certs.size..]) do |actual, expected|
certs.zip([CA_CERT, SERVER_CERT][-certs.size..-1]) do |actual, expected|
assert_equal(expected.to_der, actual.to_der)
end
rescue SystemCallError
Expand All @@ -66,7 +66,7 @@ def test_get_SNI
assert_equal($test_net_http_data, res.body)
}
# TODO: OpenSSL 1.1.1h seems to yield only SERVER_CERT; need to check the incompatibility
certs.zip([CA_CERT, SERVER_CERT][-certs.size..]) do |actual, expected|
certs.zip([CA_CERT, SERVER_CERT][-certs.size..-1]) do |actual, expected|
assert_equal(expected.to_der, actual.to_der)
end
end
Expand Down