Changeset 34450 for trunk/tests/phpunit/tests/user/capabilities.php
- Timestamp:
- 09/22/2015 10:17:30 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/user/capabilities.php
r34449 r34450 62 62 'install_plugins' => array( 'administrator' ), 63 63 'install_themes' => array( 'administrator' ), 64 'upload_plugins' => array( 'administrator' ), 65 'upload_themes' => array( 'administrator' ), 64 66 'update_core' => array( 'administrator' ), 65 67 'update_plugins' => array( 'administrator' ), 66 68 'update_themes' => array( 'administrator' ), 67 69 'edit_theme_options' => array( 'administrator' ), 70 'customize' => array( 'administrator' ), 68 71 'export' => array( 'administrator' ), 69 72 'import' => array( 'administrator' ), … … 141 144 'install_plugins' => array(), 142 145 'install_themes' => array(), 146 'upload_plugins' => array(), 147 'upload_themes' => array(), 143 148 'update_core' => array(), 144 149 'update_plugins' => array(), … … 146 151 147 152 'edit_theme_options' => array( 'administrator' ), 153 'customize' => array( 'administrator' ), 148 154 'export' => array( 'administrator' ), 149 155 'import' => array( 'administrator' ), … … 244 250 245 251 } 252 253 $this->assertFalse( $user->has_cap( 'do_not_allow' ), "User with the {$role} role should not have the do_not_allow capability" ); 254 $this->assertFalse( user_can( $user, 'do_not_allow' ), "User with the {$role} role should not have the do_not_allow capability" ); 255 246 256 } 247 257 … … 305 315 $this->assertTrue( user_can( $user, $cap ), "Super Admins should have the {$cap} capability" ); 306 316 } 317 318 $this->assertFalse( $user->has_cap( 'do_not_allow' ), 'Super Admins should not have the do_not_allow capability' ); 319 $this->assertFalse( user_can( $user, 'do_not_allow' ), 'Super Admins should not have the do_not_allow capability' ); 307 320 } 308 321
Note: See TracChangeset
for help on using the changeset viewer.