Changeset 40080
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php
r39967 r40080 1768 1768 'type' => 'string', 1769 1769 'enum' => array_keys( get_post_stati( array( 'internal' => false ) ) ), 1770 'context' => array( ' edit' ),1770 'context' => array( 'view', 'edit' ), 1771 1771 ), 1772 1772 'type' => array( -
trunk/tests/phpunit/includes/testcase-rest-post-type-controller.php
r39556 r40080 135 135 } 136 136 137 $this->assertEquals( $post->post_status, $data['status'] ); 137 138 $this->assertEquals( $post->guid, $data['guid']['rendered'] ); 138 139 139 140 if ( 'edit' === $context ) { 140 141 $this->assertEquals( $post->guid, $data['guid']['raw'] ); 141 $this->assertEquals( $post->post_status, $data['status'] );142 142 143 143 if ( '0000-00-00 00:00:00' === $post->post_date_gmt ) { -
trunk/tests/qunit/fixtures/wp-api-generated.js
r40066 r40080 3385 3385 "modified_gmt": "2017-02-14T00:00:00", 3386 3386 "slug": "restapi-client-fixture-post", 3387 "status": "publish", 3387 3388 "type": "post", 3388 3389 "link": "http://example.org/?p=3", … … 3475 3476 "modified_gmt": "2017-02-14T00:00:00", 3476 3477 "slug": "restapi-client-fixture-post", 3478 "status": "publish", 3477 3479 "type": "post", 3478 3480 "link": "http://example.org/?p=3", … … 3553 3555 "modified_gmt": "2017-02-14T00:00:00", 3554 3556 "slug": "restapi-client-fixture-page", 3557 "status": "publish", 3555 3558 "type": "page", 3556 3559 "link": "http://example.org/?page_id=5", … … 3627 3630 "modified_gmt": "2017-02-14T00:00:00", 3628 3631 "slug": "restapi-client-fixture-page", 3632 "status": "publish", 3629 3633 "type": "page", 3630 3634 "link": "http://example.org/?page_id=5", … … 3701 3705 "modified_gmt": "2017-02-14T00:00:00", 3702 3706 "slug": "restapi-client-fixture-attachment", 3707 "status": "inherit", 3703 3708 "type": "attachment", 3704 3709 "link": "http://example.org/?attachment_id=7", … … 3759 3764 "modified_gmt": "2017-02-14T00:00:00", 3760 3765 "slug": "restapi-client-fixture-attachment", 3766 "status": "inherit", 3761 3767 "type": "attachment", 3762 3768 "link": "http://example.org/?attachment_id=7",
Note: See TracChangeset
for help on using the changeset viewer.