Ruby Test::Unit::TestResult Functions

EditRocket provides the following information on Test::Unit::TestResult functions in the Ruby source code builder.

add_assertion() - Records an individual assertion.

add_error(error) - Records a Test::Unit::Error.

add_failure(failure) - Records a Test::Unit::Failure.

add_run() - Records a test run.

error_count() - Returns the number of errors this TestResult has recorded.

failure_count() - Returns the number of failures this TestResult has recorded.

new() - Constructs a new, empty TestResult.

passed?() - Returns whether or not this TestResult represents successful completion.

to_s() - Returns a string contain the recorded runs, assertions, failures and errors in this TestResult.