Line | |
---|
1 | <?php |
---|
2 | set_include_path('/Users/james/Projects/PEAR' . PATH_SEPARATOR . get_include_path()); |
---|
3 | require_once 'PEAR/Config.php'; |
---|
4 | require_once 'XML/Feed/Parser.php'; |
---|
5 | require_once 'PHPUnit.php'; |
---|
6 | |
---|
7 | abstract class XML_Feed_Parser_TestCase extends PHPUnit_Testcase { |
---|
8 | static function getSampleDir() { |
---|
9 | $config = new PEAR_Config; |
---|
10 | return $config->get('data_dir') . '/XML_Feed_Parser/samples'; |
---|
11 | } |
---|
12 | } |
---|
13 | |
---|
14 | abstract class XML_Feed_Parser_Converted_TestCase extends XML_Feed_Parser_TestCase { |
---|
15 | function setup() { |
---|
16 | $this->fp_test_dir = XML_Feed_Parser_TestCase::getSampleDir() . |
---|
17 | DIRECTORY_SEPARATOR . 'feedparsertests'; |
---|
18 | if (! is_dir($fp_test_dir)) { |
---|
19 | throw new Exception('Feed parser tests must be unpacked into the folder ' . |
---|
20 | $this->fp_test_dir); |
---|
21 | } |
---|
22 | } |
---|
23 | } |
---|
24 | |
---|
25 | ?> |
---|
Note: See
TracBrowser
for help on using the repository browser.