Changeset 48937 for trunk/tests/phpunit/tests/xmlrpc/wp/deleteTerm.php
- Timestamp:
- 09/02/2020 12:35:36 AM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/xmlrpc/wp/deleteTerm.php
r46586 r48937 18 18 $result = $this->myxmlrpcserver->wp_deleteTerm( array( 1, 'username', 'password', 'category', 0 ) ); 19 19 $this->assertIXRError( $result ); 20 $this->assert Equals( 403, $result->code );20 $this->assertSame( 403, $result->code ); 21 21 } 22 22 … … 26 26 $result = $this->myxmlrpcserver->wp_deleteTerm( array( 1, 'subscriber', 'subscriber', '', 0 ) ); 27 27 $this->assertIXRError( $result ); 28 $this->assert Equals( 403, $result->code );29 $this->assert Equals( __( 'Invalid taxonomy.' ), $result->message );28 $this->assertSame( 403, $result->code ); 29 $this->assertSame( __( 'Invalid taxonomy.' ), $result->message ); 30 30 } 31 31 … … 35 35 $result = $this->myxmlrpcserver->wp_deleteTerm( array( 1, 'subscriber', 'subscriber', 'not_existing', 0 ) ); 36 36 $this->assertIXRError( $result ); 37 $this->assert Equals( 403, $result->code );38 $this->assert Equals( __( 'Invalid taxonomy.' ), $result->message );37 $this->assertSame( 403, $result->code ); 38 $this->assertSame( __( 'Invalid taxonomy.' ), $result->message ); 39 39 } 40 40 … … 44 44 $result = $this->myxmlrpcserver->wp_deleteTerm( array( 1, 'subscriber', 'subscriber', 'category', self::$term_id ) ); 45 45 $this->assertIXRError( $result ); 46 $this->assert Equals( 401, $result->code );47 $this->assert Equals( __( 'Sorry, you are not allowed to delete this term.' ), $result->message );46 $this->assertSame( 401, $result->code ); 47 $this->assertSame( __( 'Sorry, you are not allowed to delete this term.' ), $result->message ); 48 48 } 49 49 … … 53 53 $result = $this->myxmlrpcserver->wp_deleteTerm( array( 1, 'editor', 'editor', 'category', '' ) ); 54 54 $this->assertIXRError( $result ); 55 $this->assert Equals( 500, $result->code );56 $this->assert Equals( __( 'Empty Term.' ), $result->message );55 $this->assertSame( 500, $result->code ); 56 $this->assertSame( __( 'Empty Term.' ), $result->message ); 57 57 } 58 58 … … 62 62 $result = $this->myxmlrpcserver->wp_deleteTerm( array( 1, 'editor', 'editor', 'category', 9999 ) ); 63 63 $this->assertIXRError( $result ); 64 $this->assert Equals( 404, $result->code );65 $this->assert Equals( __( 'Invalid term ID.' ), $result->message );64 $this->assertSame( 404, $result->code ); 65 $this->assertSame( __( 'Invalid term ID.' ), $result->message ); 66 66 } 67 67
Note: See TracChangeset
for help on using the changeset viewer.