summaryrefslogtreecommitdiff
path: root/ext/spl/tests/iterator_057.phpt
blob: 602c1250155be3d68692cf96f426fd9cc22c431f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
--TEST--
SPL: ArrayIterator::__construct(void)
--CREDITS--
Sebastian Schürmann
--FILE--
<?php
/**
 * From Docs: Construct a new array iterator from anything that has a hash table. 
 * NULL, NOTHING is not a hash table ;) 
 */
class myArrayIterator extends ArrayIterator {
}
try {
	$it = new myArrayIterator();
} catch (InvalidArgumentException $e) {
	echo 'InvalidArgumentException thrown';
}
echo 'no Exception thrown'
?>
--EXPECT--
no Exception thrown