Changeset 51331 for trunk/tests/phpunit/tests/xmlrpc/wp/getPost.php
- Timestamp:
- 07/05/2021 05:21:53 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/xmlrpc/wp/getPost.php
r49184 r51331 43 43 44 44 // Check data types. 45 $this->assertI nternalType( 'string',$result['post_id'] );46 $this->assertI nternalType( 'string',$result['post_title'] );45 $this->assertIsString( $result['post_id'] ); 46 $this->assertIsString( $result['post_title'] ); 47 47 $this->assertInstanceOf( 'IXR_Date', $result['post_date'] ); 48 48 $this->assertInstanceOf( 'IXR_Date', $result['post_date_gmt'] ); 49 49 $this->assertInstanceOf( 'IXR_Date', $result['post_modified'] ); 50 50 $this->assertInstanceOf( 'IXR_Date', $result['post_modified_gmt'] ); 51 $this->assertI nternalType( 'string',$result['post_status'] );52 $this->assertI nternalType( 'string',$result['post_type'] );53 $this->assertI nternalType( 'string',$result['post_name'] );54 $this->assertI nternalType( 'string',$result['post_author'] );55 $this->assertI nternalType( 'string',$result['post_password'] );56 $this->assertI nternalType( 'string',$result['post_excerpt'] );57 $this->assertI nternalType( 'string',$result['post_content'] );58 $this->assertI nternalType( 'string',$result['link'] );59 $this->assertI nternalType( 'string',$result['comment_status'] );60 $this->assertI nternalType( 'string',$result['ping_status'] );61 $this->assertI nternalType( 'bool',$result['sticky'] );62 $this->assertI nternalType( 'string',$result['post_format'] );63 $this->assertI nternalType( 'array',$result['post_thumbnail'] );64 $this->assertI nternalType( 'array',$result['custom_fields'] );51 $this->assertIsString( $result['post_status'] ); 52 $this->assertIsString( $result['post_type'] ); 53 $this->assertIsString( $result['post_name'] ); 54 $this->assertIsString( $result['post_author'] ); 55 $this->assertIsString( $result['post_password'] ); 56 $this->assertIsString( $result['post_excerpt'] ); 57 $this->assertIsString( $result['post_content'] ); 58 $this->assertIsString( $result['link'] ); 59 $this->assertIsString( $result['comment_status'] ); 60 $this->assertIsString( $result['ping_status'] ); 61 $this->assertIsBool( $result['sticky'] ); 62 $this->assertIsString( $result['post_format'] ); 63 $this->assertIsArray( $result['post_thumbnail'] ); 64 $this->assertIsArray( $result['custom_fields'] ); 65 65 66 66 // Check expected values. … … 138 138 $this->assertNotIXRError( $result ); 139 139 140 $this->assertI nternalType( 'string',$result['post_id'] );141 $this->assertI nternalType( 'string',$result['post_parent'] );142 $this->assertI nternalType( 'int',$result['menu_order'] );143 $this->assertI nternalType( 'string',$result['guid'] );144 $this->assertI nternalType( 'string',$result['post_mime_type'] );140 $this->assertIsString( $result['post_id'] ); 141 $this->assertIsString( $result['post_parent'] ); 142 $this->assertIsInt( $result['menu_order'] ); 143 $this->assertIsString( $result['guid'] ); 144 $this->assertIsString( $result['post_mime_type'] ); 145 145 146 146 $this->assertSame( 'page', $result['post_type'] );
Note: See TracChangeset
for help on using the changeset viewer.