diff options
Diffstat (limited to 'ext/reflection/tests/ReflectionMethod_getClosure_error.phpt')
| -rw-r--r-- | ext/reflection/tests/ReflectionMethod_getClosure_error.phpt | 25 |
1 files changed, 2 insertions, 23 deletions
diff --git a/ext/reflection/tests/ReflectionMethod_getClosure_error.phpt b/ext/reflection/tests/ReflectionMethod_getClosure_error.phpt index d3b9ca3c81..d1e7ee68fb 100644 --- a/ext/reflection/tests/ReflectionMethod_getClosure_error.phpt +++ b/ext/reflection/tests/ReflectionMethod_getClosure_error.phpt @@ -35,15 +35,7 @@ $staticmethod = $staticclass->getMethod( 'foo' ); $object = new Example(); $fakeobj = new StdClass(); -echo "\n-- Testing ReflectionMethod::getClosure() function with more than expected no. of arguments --\n"; -var_dump( $staticmethod->getClosure( 'foobar' ) ); -var_dump( $staticmethod->getClosure( 'foo', 'bar' ) ); -var_dump( $method->getClosure( $object, 'foobar' ) ); - -echo "\n-- Testing ReflectionMethod::getClosure() function with Zero arguments --\n"; -$closure = $method->getClosure(); - -echo "\n-- Testing ReflectionMethod::getClosure() function with Zero arguments --\n"; +echo "\n-- Testing ReflectionMethod::getClosure() function with invalid object --\n"; try { var_dump( $method->getClosure( $fakeobj ) ); } catch( Exception $e ) { @@ -55,19 +47,6 @@ try { --EXPECTF-- *** Testing ReflectionMethod::getClosure() : error conditions *** --- Testing ReflectionMethod::getClosure() function with more than expected no. of arguments -- -object(Closure)#%d (0) { -} -object(Closure)#%d (0) { -} - -Warning: ReflectionMethod::getClosure() expects exactly 1 parameter, 2 given in %s on line %d -NULL - --- Testing ReflectionMethod::getClosure() function with Zero arguments -- - -Warning: ReflectionMethod::getClosure() expects exactly 1 parameter, 0 given in %s on line %d - --- Testing ReflectionMethod::getClosure() function with Zero arguments -- +-- Testing ReflectionMethod::getClosure() function with invalid object -- string(72) "Given object is not an instance of the class this method was declared in" ===DONE=== |
