| 32 | | // TODO |
|---|
| | 32 | // Get the list of test files |
|---|
| | 33 | $finder = sfFinder::type('file')->follow_link()->name('*Test.php'); |
|---|
| | 34 | $testFiles = $finder->in(sfConfig::get('sf_test_dir')); |
|---|
| | 35 | |
|---|
| | 36 | // Check to see if any test files were found |
|---|
| | 37 | if (!is_array($testFiles) || count($testFiles) < 1) |
|---|
| | 38 | { |
|---|
| | 39 | throw new Exception('You must register some test files before running them!'); |
|---|
| | 40 | } |
|---|
| | 41 | |
|---|
| | 42 | // Create a new output generator |
|---|
| | 43 | $outputGenerator = new sfTestsToXUnitOutput($options['path']); |
|---|
| | 44 | |
|---|
| | 45 | // For each test |
|---|
| | 46 | /*foreach($testFiles as $testFile) |
|---|
| | 47 | { |
|---|
| | 48 | // Create a new test |
|---|
| | 49 | $test = new sfTestsToXUnitTest($testFile, $options['phpcli']); |
|---|
| | 50 | $test->executeTest($outputGenerator); |
|---|
| | 51 | }*/ |
|---|
| | 52 | |
|---|
| | 53 | // Test test |
|---|
| | 54 | $test = new sfTestsToXUnitTest('D:\Work\MadeByPi\First Direct\Q3\Trunk\Code\Symfony Project\test\unit\DOMDocumentUtilTest.php', $options['phpcli']); |
|---|
| | 55 | $test->executeTest($outputGenerator); |
|---|
| | 56 | |
|---|
| | 57 | // Output the tests information in XUnit format |
|---|
| | 58 | $outputGenerator->output(); |
|---|