[wp-trac] [WordPress Trac] #37910: Remove confusing legacy logic in date_i18n()
WordPress Trac
noreply at wordpress.org
Wed Nov 2 22:55:31 UTC 2016
#37910: Remove confusing legacy logic in date_i18n()
---------------------------+-------------------------
Reporter: jdgrimes | Owner: swissspidy
Type: enhancement | Status: reopened
Priority: normal | Milestone: 4.7
Component: Date/Time | Version: 3.0
Severity: normal | Resolution:
Keywords: needs-testing | Focuses:
---------------------------+-------------------------
Comment (by swissspidy):
`Tests_Date_I18n::test_adjusts_format_based_on_timezone_string()` was
added to cover [https://core.trac.wordpress.org/browser/trunk/src/wp-
includes/functions.php?rev=39098&marks=120-136#L120 this part of
`date_i18n()`] which replaces date format strings based on the site's
timezone. So it's not really about comparing the time, but about checking
whether that replacement works as expected. Hence the unusual date format
string.
The logic in `date_i18n()` is still valid, but the test is faulty. I need
to replace it with something a bit more flexible.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/37910#comment:15>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list