![]() ![]() | ![]() |
1.1 misho 1: --TEST-- 2: SPL: SplHeap top of empty heap 3: --CREDITS-- 4: Mark Schaschke (mark@fractalturtle.com) 5: TestFest London May 2009 6: --FILE-- 7: <?php 8: $h = new SplMinHeap(); 9: try { 10: $h->top(); 11: } catch (Exception $e) { 12: echo $e->getMessage(); 13: } 14: ?> 15: --EXPECTF-- 16: Can't peek at an empty heap