From a075b34736458e90c568b7c064adbd617206ce0b Mon Sep 17 00:00:00 2001 From: Olle Jonsson Date: Sat, 20 Jan 2018 15:26:49 +0100 Subject: [PATCH 1/3] Travis CI matrix: add 2.4, 2.5 --- .travis.yml | 2 ++ test/test_net_http_persistent.rb | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 21ab797..255a5b7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,4 +12,6 @@ rvm: - 2.1.10 - 2.2.5 - 2.3.1 +- 2.4 +- 2.5 script: rake travis diff --git a/test/test_net_http_persistent.rb b/test/test_net_http_persistent.rb index fa64570..e37a2fc 100644 --- a/test/test_net_http_persistent.rb +++ b/test/test_net_http_persistent.rb @@ -120,7 +120,7 @@ def proxy_port def basic_connection raise "#{@uri} is not HTTP" unless @uri.scheme.downcase == 'http' - net_http_args = [@uri.host, @uri.port] + net_http_args = [@uri.hostname, @uri.port] connection = Net::HTTP::Persistent::Connection.allocate connection.ssl_generation = @http.ssl_generation @@ -152,7 +152,7 @@ def r.read_body() :read_body end def ssl_connection raise "#{@uri} is not HTTPS" unless @uri.scheme.downcase == 'https' - net_http_args = [@uri.host, @uri.port] + net_http_args = [@uri.hostname, @uri.port] connection = Net::HTTP::Persistent::Connection.allocate connection.ssl_generation = @http.ssl_generation From 7b893979d6d425a481f4852de657273c66f65b5b Mon Sep 17 00:00:00 2001 From: Olle Jonsson Date: Sat, 20 Jan 2018 15:42:25 +0100 Subject: [PATCH 2/3] Call connection.http.start instead of connection.start --- test/test_net_http_persistent.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/test_net_http_persistent.rb b/test/test_net_http_persistent.rb index e37a2fc..f80d3c8 100644 --- a/test/test_net_http_persistent.rb +++ b/test/test_net_http_persistent.rb @@ -751,7 +751,7 @@ def test_pipeline skip 'net-http-pipeline not installed' unless defined?(Net::HTTP::Pipeline) cached = basic_connection - cached.start + cached.http.start requests = [ Net::HTTP::Get.new((@uri + '1').request_uri), From ef2fc1cdffe2c4b8ec035c72e85fa2a83e5adb73 Mon Sep 17 00:00:00 2001 From: Olle Jonsson Date: Tue, 2 Apr 2019 13:56:38 +0200 Subject: [PATCH 3/3] CI: Use 2.4.6, 2.5.5, 2.6.2 --- .travis.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 255a5b7..a196efa 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,6 +12,7 @@ rvm: - 2.1.10 - 2.2.5 - 2.3.1 -- 2.4 -- 2.5 +- 2.4.6 +- 2.5.5 +- 2.6.2 script: rake travis