Annotation of embedaddon/php/ext/reflection/tests/ReflectionFunction_getClosure_error.phpt, revision 1.1

1.1     ! misho       1: --TEST--
        !             2: Test ReflectionFunction::getClosure() function : error functionality
        !             3: --FILE--
        !             4: <?php
        !             5: /* Prototype  : public mixed ReflectionFunction::getClosure()
        !             6:  * Description: Returns a dynamically created closure for the function
        !             7:  * Source code: ext/reflection/php_reflection.c
        !             8:  * Alias to functions:
        !             9:  */
        !            10: 
        !            11: echo "*** Testing ReflectionFunction::getClosure() : error conditions ***\n";
        !            12: 
        !            13: function foo()
        !            14: {
        !            15:        var_dump( "Inside foo function" );
        !            16: }
        !            17: 
        !            18: $func = new ReflectionFunction( 'foo' );
        !            19: $closure = $func->getClosure('bar');
        !            20: 
        !            21: ?>
        !            22: ===DONE===
        !            23: --EXPECTF--
        !            24: *** Testing ReflectionFunction::getClosure() : error conditions ***
        !            25: 
        !            26: Warning: ReflectionFunction::getClosure() expects exactly 0 parameters, 1 given in %s on line %d
        !            27: ===DONE===

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