* @extends PHPUnit_TestCase * @version $Id: XML_RSS_Infrastructure_Test.php 295062 2010-02-14 14:43:35Z cweiske $ */ class XML_RSS_Infrastructure_Test extends PHPUnit_Framework_TestCase { public static function main() { require_once 'PHPUnit/TextUI/TestRunner.php'; PHPUnit_TextUI_TestRunner::run( new PHPUnit_Framework_TestSuite('XML_RSS_Infrastructure_Test') ); } /** * Test case for making sure that XML_RSS extends from XML_Parser */ function testIsXML_Parser() { $rss =& new XML_RSS(); $this->assertTrue(is_a($rss, "XML_Parser")); } /** * Test case for bug report #2310 * * @link http://pear.php.net/bugs/2310/ */ function testBug2310() { $rss =& new XML_RSS("", null, "utf-8"); $this->assertEquals($rss->tgtenc, "utf-8"); $rss =& new XML_RSS("", "utf-8", "iso-8859-1"); $this->assertEquals($rss->srcenc, "utf-8"); $this->assertEquals($rss->tgtenc, "iso-8859-1"); } } if (PHPUnit_MAIN_METHOD == 'XML_RSS_Infrastructure_Test::main') { XML_RSS_Infrastructure_Test::main(); } ?>