summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--test/ruby/test_module.rb1
-rw-r--r--tool/lib/core_assertions.rb2
-rw-r--r--tool/lib/test/unit/assertions.rb1
-rw-r--r--tool/lib/test/unit/testcase.rb6
-rw-r--r--tool/test/webrick/utils.rb2
5 files changed, 7 insertions, 5 deletions
diff --git a/test/ruby/test_module.rb b/test/ruby/test_module.rb
index 59b3df5f04..98c9128406 100644
--- a/test/ruby/test_module.rb
+++ b/test/ruby/test_module.rb
@@ -1046,6 +1046,7 @@ class TestModule < Test::Unit::TestCase
def test_attr_obsoleted_flag
c = Class.new do
+ extend Test::Unit::Assertions
extend Test::Unit::CoreAssertions
def initialize
@foo = :foo
diff --git a/tool/lib/core_assertions.rb b/tool/lib/core_assertions.rb
index 5720eb1ac3..f94a5dff66 100644
--- a/tool/lib/core_assertions.rb
+++ b/tool/lib/core_assertions.rb
@@ -25,9 +25,7 @@ module Test
module CoreAssertions
require_relative 'envutil'
-
require 'pp'
- include Test::Unit::Assertions
def mu_pp(obj) #:nodoc:
obj.pretty_inspect.chomp
diff --git a/tool/lib/test/unit/assertions.rb b/tool/lib/test/unit/assertions.rb
index db8128536c..bdb25d0d85 100644
--- a/tool/lib/test/unit/assertions.rb
+++ b/tool/lib/test/unit/assertions.rb
@@ -1,5 +1,4 @@
# frozen_string_literal: true
-require_relative '../../core_assertions'
require 'pp'
module Test
diff --git a/tool/lib/test/unit/testcase.rb b/tool/lib/test/unit/testcase.rb
index 6ce9f5940d..ea3092a4b3 100644
--- a/tool/lib/test/unit/testcase.rb
+++ b/tool/lib/test/unit/testcase.rb
@@ -1,5 +1,6 @@
# frozen_string_literal: true
require 'test/unit/assertions'
+require_relative '../../core_assertions'
module Test
module Unit
@@ -143,6 +144,9 @@ module Test
# See MiniTest::Assertions
class TestCase
+ include Assertions
+ include CoreAssertions
+
include LifecycleHooks
include Guard
extend Guard
@@ -332,8 +336,6 @@ module Test
def teardown; end
- include CoreAssertions
-
def on_parallel_worker?
false
end
diff --git a/tool/test/webrick/utils.rb b/tool/test/webrick/utils.rb
index 85fc2bc641..a8568d0a43 100644
--- a/tool/test/webrick/utils.rb
+++ b/tool/test/webrick/utils.rb
@@ -36,6 +36,8 @@ module TestWEBrick
RubyBinArray << "-I" << "#{File.dirname(EnvUtil.rubybin)}/.ext/#{RUBY_PLATFORM}"
require "test/unit" unless defined?(Test::Unit)
+ include Test::Unit::Assertions
+ extend Test::Unit::Assertions
include Test::Unit::CoreAssertions
extend Test::Unit::CoreAssertions