Annotation of embedaddon/php/ext/date/tests/date_modify-1.phpt, revision 1.1
1.1 ! misho 1: --TEST--
! 2: date_modify() function [1]
! 3: --SKIPIF--
! 4: <?php if (!function_exists('date_create')) echo "SKIP"; ?>
! 5: --FILE--
! 6: <?php
! 7: date_default_timezone_set("Pacific/Kwajalein");
! 8: $ts = date_create("Thu Aug 19 1993 23:59:59");
! 9: echo date_format($ts, 'D, d M Y H:i:s T'), "\n";
! 10: $ts->modify("+1 second");
! 11: echo date_format($ts, 'D, d M Y H:i:s T'), "\n";
! 12:
! 13: date_default_timezone_set("Europe/Amsterdam");
! 14: $ts = date_create("Sun Mar 27 01:59:59 2005");
! 15: echo date_format($ts, 'D, d M Y H:i:s T'), "\n";
! 16: $ts->modify("+1 second");
! 17: echo date_format($ts, 'D, d M Y H:i:s T'), "\n";
! 18:
! 19: $ts = date_create("Sun Oct 30 01:59:59 2005");
! 20: echo date_format($ts, 'D, d M Y H:i:s T'), "\n";
! 21: $ts->modify("+ 1 hour 1 second");
! 22: echo date_format($ts, 'D, d M Y H:i:s T'), "\n";
! 23: ?>
! 24: --EXPECT--
! 25: Thu, 19 Aug 1993 23:59:59 KWAT
! 26: Sat, 21 Aug 1993 00:00:00 MHT
! 27: Sun, 27 Mar 2005 01:59:59 CET
! 28: Sun, 27 Mar 2005 03:00:00 CEST
! 29: Sun, 30 Oct 2005 01:59:59 CEST
! 30: Sun, 30 Oct 2005 03:00:00 CET
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>