php-src/ext/spl/tests/SplQueue_setIteratorMode_param_lifo.phpt

20 lines
389 B
Plaintext
Raw Normal View History

2009-05-23 23:37:36 +08:00
--TEST--
SplQueue setIteratorMode to LIFO produces fail condition in try/catch
--CREDITS--
PHPNW Test Fest 2009 - Jeremy Coates jeremy@phpnw.org.uk
--FILE--
<?php
try {
$dll = new SplQueue();
$dll->setIteratorMode(SplDoublyLinkedList::IT_MODE_LIFO);
} catch (Exception $e) {
echo $e->getMessage();
}
?>
--EXPECT--
Iterators' LIFO/FIFO modes for SplStack/SplQueue objects are frozen