summaryrefslogtreecommitdiff
path: root/spec/ruby/library
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2021-05-06 22:04:14 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2021-05-06 22:04:14 +0900
commitddc29e29890f7f1b29effb84929e6856e45632ee (patch)
tree29a031e4777befcd0d2e31624f3f8ffad9fcd9c0 /spec/ruby/library
parentf2d6fa16e116cbb624ccc8df4cbc57422e236d46 (diff)
net-http no longer requires stringio
Diffstat (limited to 'spec/ruby/library')
-rw-r--r--spec/ruby/library/net/http/http/get_spec.rb1
-rw-r--r--spec/ruby/library/net/http/httpresponse/read_body_spec.rb1
-rw-r--r--spec/ruby/library/net/http/httpresponse/read_new_spec.rb1
-rw-r--r--spec/ruby/library/net/http/httpresponse/shared/body.rb2
4 files changed, 5 insertions, 0 deletions
diff --git a/spec/ruby/library/net/http/http/get_spec.rb b/spec/ruby/library/net/http/http/get_spec.rb
index 0948006fca..9f6c45f26b 100644
--- a/spec/ruby/library/net/http/http/get_spec.rb
+++ b/spec/ruby/library/net/http/http/get_spec.rb
@@ -30,6 +30,7 @@ describe "Net::HTTP.get" do
describe "when reading gzipped contents" do
def start_threads
require 'zlib'
+ require 'stringio'
server = nil
server_thread = Thread.new do
diff --git a/spec/ruby/library/net/http/httpresponse/read_body_spec.rb b/spec/ruby/library/net/http/httpresponse/read_body_spec.rb
index 99d8e5fa88..ec9b42f919 100644
--- a/spec/ruby/library/net/http/httpresponse/read_body_spec.rb
+++ b/spec/ruby/library/net/http/httpresponse/read_body_spec.rb
@@ -1,5 +1,6 @@
require_relative '../../../../spec_helper'
require 'net/http'
+require 'stringio'
describe "Net::HTTPResponse#read_body" do
before :each do
diff --git a/spec/ruby/library/net/http/httpresponse/read_new_spec.rb b/spec/ruby/library/net/http/httpresponse/read_new_spec.rb
index 73c7ddc100..dc2cdc9621 100644
--- a/spec/ruby/library/net/http/httpresponse/read_new_spec.rb
+++ b/spec/ruby/library/net/http/httpresponse/read_new_spec.rb
@@ -1,5 +1,6 @@
require_relative '../../../../spec_helper'
require 'net/http'
+require 'stringio'
describe "Net::HTTPResponse.read_new" do
it "creates a HTTPResponse object based on the response read from the passed socket" do
diff --git a/spec/ruby/library/net/http/httpresponse/shared/body.rb b/spec/ruby/library/net/http/httpresponse/shared/body.rb
index 91d5fe6375..618e3936fb 100644
--- a/spec/ruby/library/net/http/httpresponse/shared/body.rb
+++ b/spec/ruby/library/net/http/httpresponse/shared/body.rb
@@ -1,3 +1,5 @@
+require 'stringio'
+
describe :net_httpresponse_body, shared: true do
before :each do
@res = Net::HTTPUnknownResponse.new("1.0", "???", "test response")