Annotation of embedaddon/php/ext/spl/tests/spl_iterator_getcallchildren.phpt, revision 1.1.1.1

1.1       misho       1: --TEST--
                      2: SPL: RecursiveIteratorIterator, getCallChildren
                      3: --CREDITS--
                      4: Sean Burlington www.practicalweb.co.uk
                      5: TestFest London May 2009
                      6: --FILE--
                      7: <?php
                      8:   //line 681 ...
                      9:   $array = array(array(7,8,9),1,2,3,array(4,5,6));
                     10: $recursiveArrayIterator = new RecursiveArrayIterator($array);
                     11: $test = new RecursiveIteratorIterator($recursiveArrayIterator);
                     12: 
                     13: var_dump($test->current());
                     14: $test->next();
                     15: var_dump($test->current());
                     16: try {
                     17:   $output = $test->callGetChildren();
                     18: } catch (InvalidArgumentException $ilae){
                     19:   $output = null;  
                     20:   print "invalid argument exception\n";
                     21: }
                     22: var_dump($output);
                     23: 
                     24: 
                     25: ?>
                     26: ===DONE===
                     27: --EXPECTF--
                     28:   array(3) {
                     29:   [0]=>
                     30:   int(7)
                     31:   [1]=>
                     32:   int(8)
                     33:   [2]=>
                     34:   int(9)
                     35: }
                     36: int(7)
                     37: invalid argument exception
                     38: NULL
                     39: ===DONE===

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