cvs: php4 /ext/xslt/tests 004.phpt
| From: | Melvyn Sopacua | Date: | Sat, 05 Oct 2002 16:11:45 +0000 |
| Subject: | cvs: php4 /ext/xslt/tests 004.phpt | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-14570@lists.php.net to get a copy of this message | ||
msopacua Sat Oct 5 12:11:45 2002 EDT
Added files:
/php4/ext/xslt/tests 004.phpt
Log:
(xslt tests) Test for reference to a non-existing scheme handler.
Index: php4/ext/xslt/tests/004.phpt
+++ php4/ext/xslt/tests/004.phpt
--TEST--
Set a non-existing scheme handler
--SKIPIF--
<?php include("skipif.inc"); ?>
--FILE--
<?php
function bar()
{
return 1;
}
$xh = xslt_create();
$xmlstring = '<foo><barred /></foo>';
$xslstring = '<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/TR/1999/XSL/Transform"><xsl:for-each
select="/"><xsl:value-of select="document(\'bogus://foo\')"
/></xsl:for-each></xsl:stylesheet>';
xslt_set_scheme_handlers($xh, array('get_all' => 'foo'));
$result = xslt_process($xh, 'arg:/_xml', 'arg:/_xsl', NULL,
array('/_xml' => $xmlstring, '/_xsl' => $xslstring));
xslt_free($xh);
echo("OK");
?>
--EXPECT--
OK