Annotation of embedaddon/php/Zend/tests/function_exists_error.phpt, revision 1.1.1.1

1.1       misho       1: --TEST--
                      2: Test function_exists() function : error conditions 
                      3: --FILE--
                      4: <?php
                      5: /* 
                      6:  * proto bool function_exists(string function_name)
                      7:  * Function is implemented in Zend/zend_builtin_functions.c
                      8: */ 
                      9: 
                     10: echo "*** Testing function_exists() : error conditions ***\n";
                     11: 
                     12: $arg_0 = "ABC";
                     13: $extra_arg = 1;
                     14: 
                     15: echo "\nToo many arguments\n";
                     16: var_dump(function_exists($arg_0, $extra_arg));
                     17: 
                     18: echo "\nToo few arguments\n";
                     19: var_dump(function_exists());
                     20: 
                     21: ?>
                     22: ===Done===
                     23: --EXPECTF--
                     24: *** Testing function_exists() : error conditions ***
                     25: 
                     26: Too many arguments
                     27: 
                     28: Warning: function_exists() expects exactly 1 parameter, 2 given in %s on line %d
                     29: NULL
                     30: 
                     31: Too few arguments
                     32: 
                     33: Warning: function_exists() expects exactly 1 parameter, 0 given in %s on line %d
                     34: NULL
                     35: ===Done===
                     36: 

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