Return to ceil_error.phpt CVS log | Up to [ELWIX - Embedded LightWeight unIX -] / embedaddon / php / ext / standard / tests / math |
1.1 misho 1: --TEST-- 2: Test ceil() - error conditions - incorrect number of args 3: --FILE-- 4: <?php 5: /* Prototype : float ceil ( float $value ) 6: * Description: Round fractions up. 7: * Source code: ext/standard/math.c 8: */ 9: 10: echo "*** Testing ceil() : error conditions ***\n"; 11: $arg_0 = 1.0; 12: $extra_arg = 1; 13: 14: echo "\nToo many arguments\n"; 15: var_dump(ceil($arg_0, $extra_arg)); 16: 17: echo "\nToo few arguments\n"; 18: var_dump(ceil()); 19: ?> 20: ===Done=== 21: --EXPECTF-- 22: *** Testing ceil() : error conditions *** 23: 24: Too many arguments 25: 26: Warning: ceil() expects exactly 1 parameter, 2 given in %s on line %d 27: NULL 28: 29: Too few arguments 30: 31: Warning: ceil() expects exactly 1 parameter, 0 given in %s on line %d 32: NULL 33: ===Done===