class MyTestSuite extends PHPUnit_Framework_TestSuite { public static function suite() { $suite = new self(); $suite->addTestSuite('MyTestCase1'); $suite->addTestSuite('MyTestCase2'); return $suite; } }
phpunit MyTestSuite.phpIn this example, the PHPUnit command-line tool is used to run the `MyTestSuite.php` file, which contains the `MyTestSuite` test suite defined in Example 1. The tool automatically detects and runs all test cases included in the suite. Package library: PHPUnit is an open-source testing framework for PHP, so the PHPUnit_Framework_TestSuite class belongs to the PHPUnit package library.