Changeset 34580 for trunk/tests/phpunit/tests/xmlrpc/wp/editTerm.php
- Timestamp:
- 09/26/2015 05:30:34 AM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/xmlrpc/wp/editTerm.php
r25002 r34580 93 93 94 94 $result = $this->myxmlrpcserver->wp_editTerm( array( 1, 'editor', 'editor', $this->child_term['term_id'], array( 'taxonomy' => 'category', 'parent' => '', 'name' => 'test' ) ) ); 95 $this->assertInstanceOf( 'IXR_Error', $result ); 96 $this->assertEquals( 500, $result->code ); 97 $this->assertEquals( __('Empty Term'), $result->message ); 95 $this->assertNotInstanceOf( 'IXR_Error', $result ); 96 $this->assertTrue( $result ); 97 } 98 99 function test_parent_null() { 100 $this->make_user_by_role( 'editor' ); 101 102 $result = $this->myxmlrpcserver->wp_editTerm( array( 1, 'editor', 'editor', $this->child_term['term_id'], array( 'taxonomy' => 'category', 'parent' => NULL, 'name' => 'test' ) ) ); 103 104 $this->assertNotInstanceOf( 'IXR_Error', $result ); 105 $this->assertInternalType( 'boolean', $result ); 106 107 $term = get_term( $this->child_term['term_id'], 'category' ); 108 $this->assertEquals( '0', $term->parent ); 98 109 } 99 110
Note: See TracChangeset
for help on using the changeset viewer.