summaryrefslogtreecommitdiff
path: root/test/rubygems/test_gem_request.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/rubygems/test_gem_request.rb')
-rw-r--r--test/rubygems/test_gem_request.rb10
1 files changed, 6 insertions, 4 deletions
diff --git a/test/rubygems/test_gem_request.rb b/test/rubygems/test_gem_request.rb
index 0577eb6f99..5f7d7bb7be 100644
--- a/test/rubygems/test_gem_request.rb
+++ b/test/rubygems/test_gem_request.rb
@@ -93,11 +93,11 @@ class TestGemRequest < Gem::TestCase
def test_configure_connection_for_https
connection = Net::HTTP.new 'localhost', 443
- request = Class.new(Gem::Request) {
+ request = Class.new(Gem::Request) do
def self.get_cert_files
[TestGemRequest::PUBLIC_CERT_FILE]
end
- }.create_with_proxy URI('https://example'), nil, nil, nil
+ end.create_with_proxy URI('https://example'), nil, nil, nil
Gem::Request.configure_connection_for_https connection, request.cert_files
@@ -112,11 +112,11 @@ class TestGemRequest < Gem::TestCase
connection = Net::HTTP.new 'localhost', 443
- request = Class.new(Gem::Request) {
+ request = Class.new(Gem::Request) do
def self.get_cert_files
[TestGemRequest::PUBLIC_CERT_FILE]
end
- }.create_with_proxy URI('https://example'), nil, nil, nil
+ end.create_with_proxy URI('https://example'), nil, nil, nil
Gem::Request.configure_connection_for_https connection, request.cert_files
@@ -486,6 +486,7 @@ ERROR: Certificate is an invalid CA certificate
end
class Conn
+
attr_accessor :payload
def new(*args); self; end
@@ -504,6 +505,7 @@ ERROR: Certificate is an invalid CA certificate
self.payload = req
@response
end
+
end
end if defined?(OpenSSL::SSL)