Changeset 324 for cleversvg/trunk/tests/csDocumentTest.php
- Timestamp:
- 02/27/08 14:42:36 (4 years ago)
- Files:
-
- 1 modified
-
cleversvg/trunk/tests/csDocumentTest.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
cleversvg/trunk/tests/csDocumentTest.php
r323 r324 1 1 <?php 2 // Call csDocumentTest::main() if this source file is executed directly. 3 if (!defined('PHPUnit_MAIN_METHOD')) { 4 define('PHPUnit_MAIN_METHOD', 'csDocumentTest::main'); 5 } 6 2 7 require_once 'PHPUnit/Framework.php'; 3 8 require_once dirname(__FILE__).'/../cleversvg.php'; … … 15 20 */ 16 21 protected $doc; 22 23 public static function main() 24 { 25 require_once 'PHPUnit/TextUI/TestRunner.php'; 26 $suite = new PHPUnit_Framework_TestSuite('csDocumentTest'); 27 $result = PHPUnit_TextUI_TestRunner::run($suite); 28 } 17 29 18 30 public function setUp() … … 39 51 $this->assertEquals(preg_match('#<\?xml version="1.0" encoding="UTF-8".*?\?>#s', $xml), 1, $xml); 40 52 } 53 } 41 54 55 // Call csDocumentTest::main() if this source file is executed directly. 56 if (PHPUnit_MAIN_METHOD == 'csDocumentTest::main') { 57 csDocumentTest::main(); 42 58 }
