MDL-72478 calendar: Fix PHPUnit failure with offset
commit6f3450ef1ee6f9eb66e1184bb3921eaf9ca30083
authorSara Arjona <sara@moodle.com>
Fri, 3 Sep 2021 07:28:41 +0000 (3 09:28 +0200)
committerSara Arjona <sara@moodle.com>
Fri, 3 Sep 2021 07:35:11 +0000 (3 09:35 +0200)
tree755f2dc47c983defd9d27ae7db9d434413d4b437
parent089f5bb0eccf01fa846bc711a79d6c2e9a5adc92
MDL-72478 calendar: Fix PHPUnit failure with offset

Before PHP 8.0.10, the time is lost when datetime->modify() is used
with weekdays. However, with PHP 8.0.10, the time is kept.
In consequence, the test_yearly_every_20th_monday_forever method
started failing.
For fixing it, the offset has been removed and the time has been set
to 00:00, so the behaviour will be the same regardless the PHP
version.
calendar/tests/rrule_manager_test.php