Annotation of embedaddon/php/ext/date/tests/sunfuncts.phpt, revision 1.1
1.1 ! misho 1: --TEST--
! 2: date_sunrise() and date_sunset() functions
! 3: --INI--
! 4: precision=13
! 5: --FILE--
! 6: <?php
! 7: date_default_timezone_set('Asia/Jerusalem');
! 8: for($a=1;$a<=12;$a++){
! 9: echo date_sunrise(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_TIMESTAMP,31.76670,35.23330,90.83,2)." ";
! 10: echo date_sunrise(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_STRING,31.76670,35.23330,90.83,2)." ";
! 11: echo date_sunrise(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_DOUBLE,31.76670,35.23330,90.83,2)."\n";
! 12:
! 13: echo date_sunset(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_TIMESTAMP,31.76670,35.23330,90.83,2)." ";
! 14: echo date_sunset(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_STRING,31.76670,35.23330,90.83,2)." ";
! 15: echo date_sunset(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_DOUBLE,31.76670,35.23330,90.83,2)."\n";
! 16: }
! 17: ?>
! 18: --EXPECTF--
! 19: 1041395864 06:37 6.6290131458%d
! 20: 1041432452 16:47 16.792451114%d
! 21: 1044073855 06:30 6.5154089279%d
! 22: 1044112463 17:14 17.239870289%d
! 23: 1046491495 06:04 6.0822145033%d
! 24: 1046533075 17:37 17.632011035%d
! 25: 1049167581 05:26 5.4394438111%d
! 26: 1049212774 17:59 17.993035729%d
! 27: 1051757532 04:52 4.8701934126%d
! 28: 1051806007 18:20 18.335390508%d
! 29: 1054434776 04:32 4.5489827182%d
! 30: 1054485647 18:40 18.679812949%d
! 31: 1057026949 04:35 4.5971956372%d
! 32: 1057078197 18:49 18.832563396%d
! 33: 1059706409 04:53 4.8916575089%d
! 34: 1059755837 18:37 18.621440704%d
! 35: 1062385999 05:13 5.2220951121%d
! 36: 1062432291 18:04 18.080957168%d
! 37: 1064979098 05:31 5.5273199215%d
! 38: 1065021952 17:25 17.431339135%d
! 39: 1067658845 05:54 5.9016292870%d
! 40: 1067698274 16:51 16.853902453%d
! 41: 1070252387 06:19 6.3299242689%d
! 42: 1070289382 16:36 16.606312600%d
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>