xref: /PHP-8.4/ext/date/tests/bug20382-1.phpt (revision f8d79582)
1--TEST--
2Bug #20382 [1] (strtotime ("Monday", $date) produces wrong result on DST changeover)
3--INI--
4date.timezone=Europe/Amsterdam
5--FILE--
6<?php
7    $tStamp = mktime (17, 17, 17, 10, 27, 2004);
8    echo "tStamp=". date("l Y-m-d H:i:s T", $tStamp). "\n";
9
10    $strtotime_timestamp = strtotime ("Monday", $tStamp);
11    echo "result=". date("l Y-m-d H:i:s T", $strtotime_timestamp). "\n";
12    echo "wanted=Monday 2004-11-01 00:00:00 CET\n";
13?>
14--EXPECT--
15tStamp=Wednesday 2004-10-27 17:17:17 CEST
16result=Monday 2004-11-01 00:00:00 CET
17wanted=Monday 2004-11-01 00:00:00 CET
18