Annotation of embedaddon/php/ext/dom/tests/DOMComment_replaceData_error2.phpt, revision 1.1
1.1 ! misho 1: --TEST--
! 2: Test replacing data into a DOMComment basic test
! 3: --CREDITS--
! 4: Andrew Larssen <al@larssen.org>
! 5: London TestFest 2008
! 6: --SKIPIF--
! 7: <?php require_once('skipif.inc'); ?>
! 8: --FILE--
! 9: <?php
! 10:
! 11: //offset to large
! 12: $dom = new DomDocument();
! 13: $comment = $dom->createComment('test-comment');
! 14: try {
! 15: $comment->replaceData(999,4,'-inserted');
! 16: } catch (DOMException $e ) {
! 17: if ($e->getMessage() == 'Index Size Error'){
! 18: echo "Throws DOMException for offest too large\n";
! 19: }
! 20: }
! 21:
! 22: ?>
! 23: --EXPECTF--
! 24: Throws DOMException for offest too large
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>