- EXPERIMENTAL CODE WARNING
Test::Stream::Workflow::Task - Compiled form of a unit.
See Test::Stream::Manual::ToTest2 for a conversion guide.
This module is still EXPERIMENTAL. Test-Stream is now stable, but this particular module is still experimental. You are still free to use this module, but you have been warned that it may change in backwords incompatible ways. This message will be removed from this modules POD once it is considered stable.
This object is a temporary object created by a runner to process Test::Stream::Workflow::Unit objects.
You rarely encounter a task object, they are mainyl used under the hood. When you do get one you usually just want to call
iterate() on it. This can be done by treating it as a coderef.
Run the task, this should only every be done by a runner.
Sometimes tasks are recursive. This method is how they resume running in a recursive structure.
Reset the task. This is rarely needed.
- $ar = $task->args()
Get the args that will be passed to the primary actions.
- $bool = $task->finished()
Check if the task has finished running.
- $bool = $task->no_final()
True if the task is not required to generate events.
- $bool = $task->should_run()
True if there is still work to be done.
- $bool = $task->subtest()
True if the task should produce a subtest.
- $int = $task->events()
Number of events produced by the primary actions.
- $int = $task->failed()
Number of failures produced inside the primary actions.
- $int = $task->pending()
How many pending iterations remain.
- $int = $task->stage()
What stage the task is in.
- $msg = $task->exception()
If an exception has occured the message will be stored here.
- $unit = $task->unit()
Get the unit the task wraps.
- $runner = $task->runner()
Get the runner instance and/or class.
The source code repository for Test::Stream can be found at http://github.com/Test-More/Test-Stream/.
Copyright 2015 Chad Granum <firstname.lastname@example.org>.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.