Method deprecated or moved
This method is deprecated or moved on the latest stable version.
The last existing version (v1_8_7_330) is shown here.
run_suite()
public
Runs the suite the TestRunnerMediator was created with.
Show source
def run_suite
Unit.run = true
begin_time = Time.now
notify_listeners(RESET, @suite.size)
result = create_result
notify_listeners(STARTED, result)
result_listener = result.add_listener(TestResult::CHANGED) do |updated_result|
notify_listeners(TestResult::CHANGED, updated_result)
end
fault_listener = result.add_listener(TestResult::FAULT) do |fault|
notify_listeners(TestResult::FAULT, fault)
end
@suite.run(result) do |channel, value|
notify_listeners(channel, value)
end
result.remove_listener(TestResult::FAULT, fault_listener)
result.remove_listener(TestResult::CHANGED, result_listener)
end_time = Time.now
elapsed_time = end_time - begin_time
notify_listeners(FINISHED, elapsed_time)
return result
end