File:  [ELWIX - Embedded LightWeight unIX -] / embedaddon / php / ext / dom / tests / DOMDocumentFragment_appendXML_error_003.phpt
Revision 1.1: download - view: text, annotated - select for diffs - revision graph
Tue Feb 21 23:47:54 2012 UTC (12 years, 5 months ago) by misho
CVS tags: MAIN, HEAD
Initial revision

--TEST--
DOMDocumentFragment::appendXML() with unbalanced chunks.
--CREDITS--
Eric Lee Stewart <ericleestewart@gmail.com>
# TestFest Atlanta 2009-05-24
--SKIPIF--
<?php require_once('skipif.inc'); ?>
--FILE--
<?php
$document = new DOMDocument;
$root = $document->createElement('root');
$document->appendChild($root);

$fragment = $document->createDocumentFragment();
@$fragment->appendXML('<foo>is<bar>great</foo>');
$root->appendChild($fragment);
?>
--EXPECTF--
Warning: DOMNode::appendChild(): Document Fragment is empty in %s on line %d

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>