Suite (Runner Class)
The Suite runner is used with FlexUnit 4 style suites. If you are using FlexUnit .9 suites, see SuiteMethod.
The Suite Runner is used in two ways. The first way is any time RunWith
is specified with the Suite runner. This is the most common way the runner called. It will introspect the class and pass any public
(this is important) classes back as possible test classes. Any empty Suite will throw an InitializationError
.
Code Block |
---|
|
[Suite]
[RunWith("org.flexunit.runners.Suite")]
public class SuitesToRun
{
public var mySuite:MySuite;
public var anotherSuite:AnotherSuite;
}
|
The second way is using a request. When a request is specified with a list of classes or a method, the framework builds them into a suite class before running any of the tests.
Code Block |
---|
|
core = new FlexUnitCore();
core.run( Request.classes( MyTestClass, AnotherTestClass );
|
Back