[wp-trac] [WordPress Trac] #34962: Issues with wp_get_document_title function causing problems with document titles
WordPress Trac
noreply at wordpress.org
Sun Jan 3 06:54:13 UTC 2016
#34962: Issues with wp_get_document_title function causing problems with document
titles
--------------------------------------+-----------------------
Reporter: kasia_codeword | Owner: obenland
Type: defect (bug) | Status: assigned
Priority: normal | Milestone: 4.4.1
Component: Themes | Version: 4.4
Severity: normal | Resolution:
Keywords: has-patch has-unit-tests | Focuses:
--------------------------------------+-----------------------
Comment (by nacin):
I mostly follow this logic. The patch looks good.
For the unit test: there's no need to reset the option at the end of the
test. This would only run if the test succeeded — if the test failed, the
reset would happen and then it'd spill over into other tests. The fix
normally would be to thus use a `tearDown()` method. However, in this
case, our `WP_UnitTestCase` automatically rolls back database writes as
well as resets the internal object cache. So given that, we can just
remove that line.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/34962#comment:10>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list