NAME
Test2::Harness::Result - Representation of a complete test
DESCRIPTION
This object is used to represent a complete test.
METHODS
- $filename = $r->file
-
Get the filename of the running test.
- $name = $r->name
-
Get the name of the file.
- $job_id = $r->job
-
Get the job id.
- $int = $r->total
-
Number of events that have incremented the test count.
- $int = $r->failed
-
Number of failures/errors seen.
- $ts = $r->start_time
-
Timestamp from object creation.
- $ts = $r->stop_time
-
Timestamp from when the test stopped.
- $exit = $r->exit
-
If the test is complete this will have the exit code. This is undefined while the test is running.
- $plans_ref = $r->plans
-
Get a list of all plans encountered. If this has more than 1 plan an error will be rendered and the test will be considered a failure.
- $events_ref = $r->planning
-
Get a list of all events that are involved in planning. This includes all plan events, and all events that increment the test count.
- $errors_ref = $r->plan_errors
-
Get a list of plan errors (IE Plan and test count do not match).
- $events_ref = $r->events
-
Get a list of all the events that were seen.
- $r->stop($exit)
-
End the test, and provide the exit code.
- $bool = $r->passed
-
Check if the result is a pass.
- $bool = $r->ran_tests
-
Check if the result is for a process that ran any tests at all.
- $r->bump_failed
-
Add to the number of failures.
- $r->add_events(@events)
- $r->add_event($event)
-
Used to add and process one or more events.
SOURCE
The source code repository for Test2-Harness can be found at http://github.com/Test-More/Test2-Harness/.
MAINTAINERS
AUTHORS
COPYRIGHT
Copyright 2016 Chad Granum <exodist7@gmail.com>.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
See http://dev.perl.org/licenses/