[wp-trac] [WordPress Trac] #56468: sanitize_option() does not handle deprecated timezones correctly
WordPress Trac
noreply at wordpress.org
Fri Oct 14 06:56:15 UTC 2022
#56468: sanitize_option() does not handle deprecated timezones correctly
-------------------------------------------------+-------------------------
Reporter: jrf | Owner:
| SergeyBiryukov
Type: defect (bug) | Status: reopened
Priority: normal | Milestone: 6.1
Component: Options, Meta APIs | Version:
Severity: normal | Resolution:
Keywords: has-patch needs-testing has-unit- | Focuses:
tests |
-------------------------------------------------+-------------------------
Comment (by peterwilsoncc):
In [changeset:"54514" 54514]:
{{{
#!CommitTicketReference repository="" revision="54514"
Tests: Replace the timezone used in date/time tests.
The `Europe/Kiev` timezone has been deprecated in PHP 8.2 and replaced
with `Europe/Kyiv`.
The tests updated in this commit are testing the WordPress date/time
functionality. They are **not** testing whether WP or PHP can handle
deprecated timezone names correctly.
To ensure the tests follow the original purpose, the use of `Europe/Kiev`
within these tests is now replaced with the `Europe/Helsinki` timezone,
which is within the same timezone as `Europe/Kyiv`. This should ensure
that these tests run without issue and test what they are supposed to be
testing on every supported PHP version (unless at some point in the future
`Europe/Helsinki` would be renamed, but that's a bridge to cross if and
when).
Note: Separate tests should/will be added to ensure that relevant
date/time related functions handle a deprecated timezone correctly, but
that is not something ''these'' tests are supposed to be testing.
Follow-up to [45853], [45856], [45876], [45882], [45887], [45908],
[45914], [46577], [46154], [46580], [46864], [46974], [54207].
Props jrf, costdev, SergeyBiryukov.
Merges [54217] to the 5.8 branch.
See #56468.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/56468#comment:37>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list