blob: b94b067f4d8186020e05d25a60a4d466eb353833 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
--TEST--
Check that SplDoublyLinkedList::add throws an exception with an invalid offset argument
--FILE--
<?php
try {
$dll = new SplDoublyLinkedList();
var_dump($dll->add(12,'Offset 12 should not exist'));
} catch (OutOfRangeException $e) {
echo "Exception: ".$e->getMessage()."\n";
}
?>
--EXPECTF--
Exception: Offset invalid or out of range
|