summaryrefslogtreecommitdiff
path: root/ext/date/tests/bug73942.phpt
blob: e328ab93b7c542f7bdd0c63e8c5b9b8cd5731889 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
--TEST--
Bug #73942: $date->modify('Friday this week') doesn't return a Friday if $date is a Sunday
--FILE--
<?php
$date1 = "2017-01-08"; // this is a Sunday
$date = new \DateTime($date1);
$date->modify('Friday this week');
$dateFormat = $date->format('Y-m-d');
echo $dateFormat, "\n";
?>
--EXPECT--
2017-01-06