mirror of
https://github.com/php/php-src.git
synced 2024-09-26 20:37:29 +00:00
23 lines
390 B
Plaintext
23 lines
390 B
Plaintext
|
--TEST--
|
||
|
SPL: SplMaxHeap, Test method to comare elements
|
||
|
--CREDITS--
|
||
|
Chris Scott chris.scott@nstein.com
|
||
|
#testfest London 2009-05-09
|
||
|
--FILE--
|
||
|
<?php
|
||
|
|
||
|
class MyHeap extends SplMaxHeap
|
||
|
{
|
||
|
public function testCompare()
|
||
|
{
|
||
|
return parent::compare(1);
|
||
|
}
|
||
|
}
|
||
|
|
||
|
$heap = new MyHeap();
|
||
|
$heap->testCompare();
|
||
|
|
||
|
?>
|
||
|
--EXPECTF--
|
||
|
Warning: SplMaxHeap::compare() expects exactly 2 parameters, %s
|