Class: Test::Unit::UI::TestRunner
Relationships & Source Files | |
Extension / Inclusion / Inheritance Descendants | |
Subclasses:
|
|
Super Chains via Extension / Inclusion / Inheritance | |
Class Chain:
self,
TestRunnerUtilities
|
|
Inherits: | Object |
Defined in: | lib/test/unit/ui/testrunner.rb |
Class Method Summary
- .new(suite, options = {}) ⇒ TestRunner constructor
TestRunnerUtilities
- Extended
run | Creates a new |
start_command_line_test | Takes care of the ARGV parsing and suite determination necessary for running one of the TestRunners from the command line. |
Instance Attribute Summary
- #listeners readonly
Instance Method Summary
-
#start
Begins the test run.
- #attach_listeners private
- #diff_target_string?(string) ⇒ Boolean private
- #prepare_for_diff(from, to) private
- #setup_mediator private
- #start_mediator private
Constructor Details
.new(suite, options = {}) ⇒ TestRunner
# File 'lib/test/unit/ui/testrunner.rb', line 10
def initialize(suite, ={}) if suite.respond_to?(:suite) @suite = suite.suite else @suite = suite end @options = @listeners = @options[:listeners] || [] end
Instance Attribute Details
#listeners (readonly)
[ GitHub ]# File 'lib/test/unit/ui/testrunner.rb', line 9
attr_reader :listeners
Instance Method Details
#attach_listeners (private)
[ GitHub ]# File 'lib/test/unit/ui/testrunner.rb', line 33
def attach_listeners @listeners.each do |listener| listener.attach_to_mediator(@mediator) end end
#diff_target_string?(string) ⇒ Boolean
(private)
# File 'lib/test/unit/ui/testrunner.rb', line 43
def diff_target_string?(string) Assertions::AssertionMessage.diff_target_string?(string) end
#prepare_for_diff(from, to) (private)
[ GitHub ]# File 'lib/test/unit/ui/testrunner.rb', line 47
def prepare_for_diff(from, to) Assertions::AssertionMessage.prepare_for_diff(from, to) end
#setup_mediator (private)
[ GitHub ]# File 'lib/test/unit/ui/testrunner.rb', line 29
def setup_mediator @mediator = TestRunnerMediator.new(@suite) end
#start
Begins the test run.
# File 'lib/test/unit/ui/testrunner.rb', line 21
def start setup_mediator attach_to_mediator attach_listeners start_mediator end
#start_mediator (private)
[ GitHub ]# File 'lib/test/unit/ui/testrunner.rb', line 39
def start_mediator @mediator.run end