Current Path : /usr/local/share/pear/test/XML_Parser/tests/ |
FreeBSD hs32.drive.ne.jp 9.1-RELEASE FreeBSD 9.1-RELEASE #1: Wed Jan 14 12:18:08 JST 2015 root@hs32.drive.ne.jp:/sys/amd64/compile/hs32 amd64 |
Current File : //usr/local/share/pear/test/XML_Parser/tests/004b.phpt |
--TEST-- XML Parser: error class (PHP5 behavior) --SKIPIF-- <?php if (version_compare(PHP_VERSION, '5.0.0', 'lt')) { print 'skip - test only applies to PHP5'; } if (!extension_loaded('xml')) { print 'skip - xml extension not available'; } ?> --FILE-- <?php require_once 'XML/Parser.php'; print 'New XML_Parser: '; var_dump(strtolower(get_class($p = new XML_Parser()))); $e = $p->parseString("<?xml version='1.0' ?>\n<foo></bar>", true); if (PEAR::isError($e)) { printf("Error message: %s" . PHP_EOL, $e->getMessage()); } else { print "No error" . PHP_EOL; } ?> --EXPECT-- New XML_Parser: string(10) "xml_parser" Error message: XML_Parser: Mismatched tag at XML input line 2:12