runTests

runTests(tests: ObjectArray): Integer;

The runTests method of the JadeTestRunner class executes the test methods of all test classes in the collection specified in the tests parameter.

The tests parameter is a collection of unit test classes and individual unit test methods. For a unit test class included in the collection, all unit test methods are executed.

The test classes must all be subclasses of the JadeTestCase class.

The following example shows the use of the runTests method to run all unit test methods for the TestConvertor class and two unit test methods for the TestCalculator class.

vars
    tests : ObjectArray;
    jtr : JadeTestRunner;
begin
    create tests transient;
    tests.add(TestConvertor);
    tests.add(TestCalculator::add);
    tests.add(TestCalculator::divide);
    create jtr transient;
    jtr.runTests(tests);
epilog
    delete tests;
    delete jtr;
end;