[wp-trac] [WordPress Trac] #22686: wp.getRevisions returns auto-drafts

WordPress Trac noreply at wordpress.org
Sun Dec 2 22:39:41 UTC 2012


#22686: wp.getRevisions returns auto-drafts
--------------------------+------------------------------
 Reporter:  maxcutler     |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  XML-RPC       |     Version:  trunk
 Severity:  normal        |  Resolution:
 Keywords:  needs-patch   |
--------------------------+------------------------------

Comment (by maxcutler):

 For repro, try this unit test which fails:


 {{{
 function test_revision_count2() {
         $this->make_user_by_role( 'editor' );

         $post_id = $this->myxmlrpcserver->wp_newPost( array( 1, 'editor',
 'editor', array(
                 'post_title' => 'Original title',
                 'post_content' => 'Test'
                 ) ) );

         $result = $this->myxmlrpcserver->wp_getRevisions( array( 1,
 'editor', 'editor', $post_id ) );
         $this->assertCount( 0, $result );
 }
 }}}

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/22686#comment:3>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list