Annotation of embedaddon/php/ext/date/tests/date_sun_info_002.phpt, revision 1.1
1.1 ! misho 1: --TEST--
! 2: Test basic date_sun_info()
! 3: --FILE--
! 4: <?php
! 5: date_default_timezone_set('Europe/Oslo');
! 6: $sun_info = date_sun_info(strtotime("2007-04-13 08:31:15 UTC"), 59.21, 9.61);
! 7: foreach ($sun_info as $key => $elem )
! 8: {
! 9: echo date( 'Y-m-d H:i:s T', $elem ), " ", $key, "\n";
! 10: }
! 11: echo "Done\n";
! 12: ?>
! 13: --EXPECTF--
! 14: 2007-04-13 06:12:19 CEST sunrise
! 15: 2007-04-13 20:31:50 CEST sunset
! 16: 2007-04-13 13:22:05 CEST transit
! 17: 2007-04-13 05:28:03 CEST civil_twilight_begin
! 18: 2007-04-13 21:16:06 CEST civil_twilight_end
! 19: 2007-04-13 04:30:08 CEST nautical_twilight_begin
! 20: 2007-04-13 22:14:01 CEST nautical_twilight_end
! 21: 2007-04-13 03:14:36 CEST astronomical_twilight_begin
! 22: 2007-04-13 23:29:33 CEST astronomical_twilight_end
! 23: Done
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>