Changeset 34604 for trunk/tests/phpunit/tests/xmlrpc/wp/uploadFile.php
- Timestamp:
- 09/26/2015 08:31:57 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/xmlrpc/wp/uploadFile.php
r34602 r34604 35 35 $this->assertInternalType( 'string', $result['type'] ); 36 36 } 37 38 /**39 * @ticket 2129240 */41 function test_network_limit() {42 $this->make_user_by_role( 'editor' );43 44 update_option( 'blog_upload_space', 0 );45 46 // create attachment47 $filename = ( DIR_TESTDATA . '/images/canola.jpg' );48 $contents = file_get_contents( $filename );49 $data = array(50 'name' => 'canola.jpg',51 'type' => 'image/jpeg',52 'bits' => $contents53 );54 55 $result = $this->myxmlrpcserver->mw_newMediaObject( array( 0, 'editor', 'editor', $data ) );56 57 // Only multisite should have a limit58 if ( is_multisite() ) {59 $this->assertInstanceOf( 'IXR_Error', $result );60 } else {61 $this->assertNotInstanceOf( 'IXR_Error', $result );62 }63 }64 37 }
Note: See TracChangeset
for help on using the changeset viewer.