[wp-trac] [WordPress Trac] #35272: .menu-item-home class not applying to static front pages
WordPress Trac
noreply at wordpress.org
Mon Oct 24 16:30:33 UTC 2016
#35272: .menu-item-home class not applying to static front pages
-----------------------------------------------+-----------------------
Reporter: RachieVee | Owner: pento
Type: defect (bug) | Status: reopened
Priority: normal | Milestone: 4.7
Component: Menus | Version: 4.4
Severity: normal | Resolution:
Keywords: has-patch commit needs-unit-tests | Focuses:
-----------------------------------------------+-----------------------
Comment (by adamsilverstein):
Replying to [comment:13 christophherr]:
> Following the format of the other checks, may I suggest to cast the
get_option check to (int)?
Yes, I agree we should cast as `int` here to match the rest of code and
for safety. I had originally cast as int and removed when I discovered
strict equality worked without it.
> I'd need some pointers to get started on unit tests for menu classes /
items.
> (Seems rather daunting after reading 32367)
I have never tried writing these, might be worth asking @johnbillion how
far he got on building out tests on #32367 or looking at existing core
unit tests for menus.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/35272#comment:14>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list