Changeset 35225 for trunk/tests/phpunit/tests/user/mapMetaCap.php
- Timestamp:
- 10/16/2015 09:04:12 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/user/mapMetaCap.php
r34113 r35225 13 13 $this->user_ids = array(); 14 14 15 $this->user_id = $this->factory->user->create( array( 'role' => 'administrator' ) );16 $this->author_id = $this->factory->user->create( array( 'role' => 'administrator' ) );15 $this->user_id = self::$factory->user->create( array( 'role' => 'administrator' ) ); 16 $this->author_id = self::$factory->user->create( array( 'role' => 'administrator' ) ); 17 17 18 18 if ( isset( $GLOBALS['super_admins'] ) ) … … 249 249 */ 250 250 function test_authorless_posts_capabilties() { 251 $post_id = $this->factory->post->create( array( 'post_author' => 0, 'post_type' => 'post', 'post_status' => 'publish' ) );252 $editor = $this->factory->user->create( array( 'role' => 'editor' ) );251 $post_id = self::$factory->post->create( array( 'post_author' => 0, 'post_type' => 'post', 'post_status' => 'publish' ) ); 252 $editor = self::$factory->user->create( array( 'role' => 'editor' ) ); 253 253 254 254 $this->assertEquals( array( 'edit_others_posts', 'edit_published_posts' ), map_meta_cap( 'edit_post', $editor, $post_id ) );
Note: See TracChangeset
for help on using the changeset viewer.