MDL-56609 phpunit: Fix bogus expectation on DST changes day
commit40d45ede416fc241f0820a0dcd94569dda0a7e88
authorEloy Lafuente (stronk7) <stronk7@moodle.org>
Sun, 28 Mar 2021 12:01:22 +0000 (28 14:01 +0200)
committerEloy Lafuente (stronk7) <stronk7@moodle.org>
Tue, 27 Apr 2021 16:31:01 +0000 (27 18:31 +0200)
tree9588dcde0ec2f8013fdb08f2e6bf34b8f6eb1f73
parentff833a08dee1ffef6e445453bfa2e8c5e98abe83
MDL-56609 phpunit: Fix bogus expectation on DST changes day

Current test works ok every day of the year but the day of
DST begin changes (last Sunday of March currently).

That day, 01:00 Europe/London simply doesn't exist, because
the time is moved forward by 60 minutes.

Hence the expectation for the next cron execution is not 1 "normal"
day (24h) but 1 less hour.

Note this only happens for the current test on DST begins, the
opposite change (DST ends), happening the last Sunday of October
is not affected, because, at all effects, 01:00 is a perfectly normal
and existing hour.
lib/tests/scheduled_task_test.php