Class: Test::Unit::TestCase

Inherits:
MiniTest::Unit::TestCase show all
Includes:
Assertions
Defined in:
lib/test/unit/parallel.rb,
lib/test/unit/testcase.rb

Overview

:nodoc: all

Constant Summary

Constants included from Assertions

Assertions::MINI_DIR

Constants inherited from MiniTest::Unit::TestCase

MiniTest::Unit::TestCase::RUN_TEST_TRACE

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Assertions

#assert, #assert_block, #assert_equal, #assert_no_match, #assert_not_equal, #assert_not_nil, #assert_not_same, #assert_not_send, #assert_nothing_raised, #assert_nothing_thrown, #assert_raise, #assert_raise_with_message, #assert_respond_to, #assert_send, #assert_throw, #build_message, #message, #mu_pp

Methods inherited from MiniTest::Unit::TestCase

#run_test

Class Method Details

.method_added(name) ⇒ Object



24
25
26
27
28
29
30
31
# File 'lib/test/unit/testcase.rb', line 24

def self.method_added(name)
  return unless name.to_s.start_with?("test_")
  @test_methods ||= {}
  if @test_methods[name]
    warn "test/unit warning: method #{ self }##{ name } is redefined"
  end
  @test_methods[name] = true
end

.test_orderObject



20
21
22
# File 'lib/test/unit/testcase.rb', line 20

def self.test_order
  :sorted
end

Instance Method Details

#on_parallel_worker?Boolean

Returns:

  • (Boolean)


175
176
177
# File 'lib/test/unit/parallel.rb', line 175

def on_parallel_worker?
  true
end

#run(runner) ⇒ Object



15
16
17
18
# File 'lib/test/unit/testcase.rb', line 15

def run runner
  @options = runner.options
  super runner
end