summaryrefslogtreecommitdiff
path: root/tool/lib/test
diff options
context:
space:
mode:
Diffstat (limited to 'tool/lib/test')
-rw-r--r--tool/lib/test/unit.rb26
-rw-r--r--tool/lib/test/unit/assertions.rb2
-rw-r--r--tool/lib/test/unit/parallel.rb8
-rw-r--r--tool/lib/test/unit/testcase.rb4
4 files changed, 20 insertions, 20 deletions
diff --git a/tool/lib/test/unit.rb b/tool/lib/test/unit.rb
index 356911150d..6b9f385a3a 100644
--- a/tool/lib/test/unit.rb
+++ b/tool/lib/test/unit.rb
@@ -83,7 +83,7 @@ module Test
private
def setup_options(opts, options)
opts.separator 'minitest options:'
- opts.version = MiniTest::Unit::VERSION
+ opts.version = Test::Unit::Runner::VERSION
opts.on '-h', '--help', 'Display this help.' do
puts opts
@@ -1196,14 +1196,14 @@ module Test
# A simple hook allowing you to run a block of code after _all_ of
# the tests are done. Eg:
#
- # MiniTest::Unit.after_tests { p $debugging_info }
+ # Test::Unit::Runner.after_tests { p $debugging_info }
def self.after_tests &block
@@after_tests << block
end
##
- # Registers MiniTest::Unit to run tests at process exit
+ # Registers Test::Unit::Runner to run tests at process exit
def self.autorun
at_exit {
@@ -1221,7 +1221,7 @@ module Test
exit false if exit_code && exit_code != 0
}
- exit_code = MiniTest::Unit.new.run ARGV
+ exit_code = Test::Unit::Runner.new.run ARGV
} unless @@installed_at_exit
@@installed_at_exit = true
end
@@ -1234,7 +1234,7 @@ module Test
end
##
- # Sets MiniTest::Unit to write output to +stream+. $stdout is the default
+ # Sets Test::Unit::Runner to write output to +stream+. $stdout is the default
# output
def self.output= stream
@@ -1242,16 +1242,16 @@ module Test
end
##
- # Tells MiniTest::Unit to delegate to +runner+, an instance of a
- # MiniTest::Unit subclass, when MiniTest::Unit#run is called.
+ # Tells Test::Unit::Runner to delegate to +runner+, an instance of a
+ # Test::Unit::Runner subclass, when Test::Unit::Runner#run is called.
def self.runner= runner
@@runner = runner
end
##
- # Returns the MiniTest::Unit subclass instance that will be used
- # to run the tests. A MiniTest::Unit instance is the default
+ # Returns the Test::Unit::Runner subclass instance that will be used
+ # to run the tests. A Test::Unit::Runner instance is the default
# runner.
def self.runner
@@ -1403,13 +1403,13 @@ module Test
# Record the result of a single test. Makes it very easy to gather
# information. Eg:
#
- # class StatisticsRecorder < MiniTest::Unit
+ # class StatisticsRecorder < Test::Unit::Runner
# def record suite, method, assertions, time, error
# # ... record the results somewhere ...
# end
# end
#
- # MiniTest::Unit.runner = StatisticsRecorder.new
+ # Test::Unit::Runner.runner = StatisticsRecorder.new
#
# NOTE: record might be sent more than once per test. It will be
# sent once with the results from the test itself. If there is a
@@ -1476,7 +1476,7 @@ module Test
OptionParser.new do |opts|
opts.banner = 'minitest options:'
- opts.version = MiniTest::Unit::VERSION
+ opts.version = Test::Unit::Runner::VERSION
opts.on '-h', '--help', 'Display this help.' do
puts opts
@@ -1589,7 +1589,7 @@ module Test
alias mini_run_suite _run_suite
- # Overriding of MiniTest::Unit#puke
+ # Overriding of Test::Unit::Runner#puke
def puke klass, meth, e
# TODO:
# this overriding is for minitest feature that skip messages are
diff --git a/tool/lib/test/unit/assertions.rb b/tool/lib/test/unit/assertions.rb
index 29ace55d1d..711d8a6bc3 100644
--- a/tool/lib/test/unit/assertions.rb
+++ b/tool/lib/test/unit/assertions.rb
@@ -596,7 +596,7 @@ module Test
# Takes a block and wraps it with the runner's shared mutex.
def synchronize
- MiniTest::Unit.runner.synchronize do
+ Test::Unit::Runner.runner.synchronize do
yield
end
end
diff --git a/tool/lib/test/unit/parallel.rb b/tool/lib/test/unit/parallel.rb
index a223a9ece6..b0d8262bfc 100644
--- a/tool/lib/test/unit/parallel.rb
+++ b/tool/lib/test/unit/parallel.rb
@@ -34,10 +34,10 @@ module Test
def _run_suite(suite, type) # :nodoc:
@partial_report = []
- orig_testout = MiniTest::Unit.output
+ orig_testout = Test::Unit::Runner.output
i,o = IO.pipe
- MiniTest::Unit.output = o
+ Test::Unit::Runner.output = o
orig_stdin, orig_stdout = $stdin, $stdout
th = Thread.new do
@@ -58,7 +58,7 @@ module Test
result = [nil,nil]
end
- MiniTest::Unit.output = orig_testout
+ Test::Unit::Runner.output = orig_testout
$stdin = orig_stdin
$stdout = orig_stdout
@@ -79,7 +79,7 @@ module Test
_report "done", Marshal.dump(result)
return result
ensure
- MiniTest::Unit.output = orig_stdout
+ Test::Unit::Runner.output = orig_stdout
$stdin = orig_stdin if orig_stdin
$stdout = orig_stdout if orig_stdout
o.close if o && !o.closed?
diff --git a/tool/lib/test/unit/testcase.rb b/tool/lib/test/unit/testcase.rb
index 61877803de..bbba87f63b 100644
--- a/tool/lib/test/unit/testcase.rb
+++ b/tool/lib/test/unit/testcase.rb
@@ -111,7 +111,7 @@ module Test
# end
# end
#
- # class MiniTest::Unit::TestCase
+ # class Test::Unit::Runner::TestCase
# include MyMinitestPlugin
# end
@@ -230,7 +230,7 @@ module Test
def io
@__io__ = true
- MiniTest::Unit.output
+ Test::Unit::Runner.output
end
##