Changeset 31098 for trunk/tests/phpunit/tests/user/author.php
- Timestamp:
- 01/08/2015 07:52:52 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/user/author.php
r28362 r31098 83 83 $this->assertEquals( 1, get_the_author_posts() ); 84 84 } 85 86 /** 87 * @ticket 30904 88 */ 89 function test_get_the_author_posts_with_custom_post_type() { 90 register_post_type( 'wptests_pt' ); 91 92 $cpt_ids = $this->factory->post->create_many( 2, array( 93 'post_author' => $this->author_id, 94 'post_type' => 'wptests_pt', 95 ) ); 96 $GLOBALS['post'] = $cpt_ids[0]; 97 98 $this->assertEquals( 2, get_the_author_posts() ); 99 100 _unregister_post_type( 'wptests_pt' ); 101 } 85 102 }
Note: See TracChangeset
for help on using the changeset viewer.