WordPress.org

Make WordPress Core

Changeset 1015 in tests


Ignore:
Timestamp:
09/11/12 21:02:10 (20 months ago)
Author:
nacin
Message:

Test that XML-RPC is enabled, not disabled. see #WP21509.

File:
1 moved

Legend:

Unmodified
Added
Removed
  • trunk/tests/xmlrpc/enabled.php

    r1009 r1015  
    88 * @group xmlrpc 
    99 */ 
    10 class Tests_XMLRPC_Disabled extends WP_UnitTestCase { 
    11     function test_disabled() { 
     10class Tests_XMLRPC_Enabled extends WP_UnitTestCase { 
     11    function test_enabled() { 
    1212        $myxmlrpcserver = new wp_xmlrpc_server(); 
    1313        $result = $myxmlrpcserver->wp_getOptions( array( 1, 'username', 'password' ) ); 
    1414 
    1515        $this->assertInstanceOf( 'IXR_Error', $result ); 
    16         $this->assertEquals( 405, $result->code ); 
     16        // If disabled, 405 would result. 
     17        $this->assertEquals( 403, $result->code ); 
    1718    } 
    1819} 
Note: See TracChangeset for help on using the changeset viewer.