Annotation of embedaddon/php/ext/date/tests/gmmktime_variation7.phpt, revision 1.1
1.1 ! misho 1: --TEST--
! 2: Test gmmktime() function : usage variation - Checking with few optional arguments.
! 3: --FILE--
! 4: <?php
! 5: /* Prototype : int gmmktime([int hour [, int min [, int sec [, int mon [, int day [, int year]]]]]])
! 6: * Description: Get UNIX timestamp for a GMT date
! 7: * Source code: ext/date/php_date.c
! 8: * Alias to functions:
! 9: */
! 10:
! 11: echo "*** Testing gmmktime() : usage variation ***\n";
! 12:
! 13: // Initialise all required variables
! 14: $hour = 8;
! 15: $min = 8;
! 16: $sec = 8;
! 17: $mon = 8;
! 18: $day = 8;
! 19:
! 20: echo "\n-- Testing gmmktime() function with one optional argument --\n";
! 21: var_dump( gmmktime($hour) );
! 22:
! 23: echo "\n-- Testing gmmktime() function with two optional argument --\n";
! 24: var_dump( gmmktime($hour, $min) );
! 25:
! 26: echo "\n-- Testing gmmktime() function with three optional argument --\n";
! 27: var_dump( gmmktime($hour, $min, $sec) );
! 28:
! 29: echo "\n-- Testing gmmktime() function with four optional argument --\n";
! 30: var_dump( gmmktime($hour, $min, $sec, $mon) );
! 31:
! 32: echo "\n-- Testing gmmktime() function with five optional argument --\n";
! 33: var_dump( gmmktime($hour, $min, $sec, $mon, $day) );
! 34:
! 35: ?>
! 36: ===DONE===
! 37: --EXPECTF--
! 38: *** Testing gmmktime() : usage variation ***
! 39:
! 40: -- Testing gmmktime() function with one optional argument --
! 41: int(%d)
! 42:
! 43: -- Testing gmmktime() function with two optional argument --
! 44: int(%d)
! 45:
! 46: -- Testing gmmktime() function with three optional argument --
! 47: int(%d)
! 48:
! 49: -- Testing gmmktime() function with four optional argument --
! 50: int(%d)
! 51:
! 52: -- Testing gmmktime() function with five optional argument --
! 53: int(%d)
! 54: ===DONE===
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>