[wp-trac] [WordPress Trac] #27205: Unit tests: super admin privledges leak to other tests
WordPress Trac
noreply at wordpress.org
Tue Feb 25 17:38:29 UTC 2014
#27205: Unit tests: super admin privledges leak to other tests
------------------------------+--------------------
Reporter: jdgrimes | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 3.9
Component: Build/Test Tools | Version: trunk
Severity: normal | Resolution:
Keywords: has-patch | Focuses:
------------------------------+--------------------
Comment (by nacin):
Well this is embarrassing. grant_super_admin() only works once per
pageload. It checks the $super_admins global and bails if it is set, then
proceeds to set it. [attachment:27205.3.diff] is a unit test that fails.
get_super_admins() consults $super_admins directly, but as this function
is called fairly often, I wonder if this was accidentally done for speed
purposes.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/27205#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list