summaryrefslogtreecommitdiff
path: root/tool/test
diff options
context:
space:
mode:
authorHiroshi SHIBATA <hsbt@ruby-lang.org>2021-05-18 16:48:16 +0900
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2021-05-18 17:31:42 +0900
commit8ab2afb20b000396ef82fb428b9bfdfa0e13d816 (patch)
treef4f7be782444b7197382d9930bfeb7dd9bb53896 /tool/test
parent0d343bf823ae0f9e2281329cc1ac7f3db454fc20 (diff)
Use Test::Unit instead of Minitest::Unit
Diffstat (limited to 'tool/test')
-rw-r--r--tool/test/webrick/test_httpresponse.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/tool/test/webrick/test_httpresponse.rb b/tool/test/webrick/test_httpresponse.rb
index 89a0f7036e..4410f63e89 100644
--- a/tool/test/webrick/test_httpresponse.rb
+++ b/tool/test/webrick/test_httpresponse.rb
@@ -1,11 +1,11 @@
# frozen_string_literal: false
require "webrick"
-require "minitest/autorun"
+require "test/unit"
require "stringio"
require "net/http"
module WEBrick
- class TestHTTPResponse < MiniTest::Unit::TestCase
+ class TestHTTPResponse < Test::Unit::TestCase
class FakeLogger
attr_reader :messages
@@ -94,14 +94,14 @@ module WEBrick
def test_set_redirect_response_splitting
url = "malicious\r\nCookie: cracked_indicator_for_test"
- assert_raises(URI::InvalidURIError) do
+ assert_raise(URI::InvalidURIError) do
res.set_redirect(WEBrick::HTTPStatus::MultipleChoices, url)
end
end
def test_set_redirect_html_injection
url = 'http://example.com////?a</a><head></head><body><img src=1></body>'
- assert_raises(WEBrick::HTTPStatus::MultipleChoices) do
+ assert_raise(WEBrick::HTTPStatus::MultipleChoices) do
res.set_redirect(WEBrick::HTTPStatus::MultipleChoices, url)
end
res.status = 300