- Timestamp:
- 11/05/2019 11:17:01 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/rest-api/rest-posts-controller.php
r46670 r46671 331 331 332 332 public function test_get_items_include_query() { 333 $id1 = $this->factory->post->create( array( 334 'post_status' => 'publish', 335 'post_date' => '2001-02-03 04:05:06', 336 ) ); 337 $id2 = $this->factory->post->create( array( 338 'post_status' => 'publish', 339 'post_date' => '2001-02-03 04:05:07', 340 ) ); 333 $id1 = $this->factory->post->create( 334 array( 335 'post_status' => 'publish', 336 'post_date' => '2001-02-03 04:05:06', 337 ) 338 ); 339 $id2 = $this->factory->post->create( 340 array( 341 'post_status' => 'publish', 342 'post_date' => '2001-02-03 04:05:07', 343 ) 344 ); 341 345 342 346 $request = new WP_REST_Request( 'GET', '/wp/v2/posts' ); … … 350 354 $this->assertPostsOrderedBy( '{posts}.post_date DESC' ); 351 355 352 // 'orderby' => 'include' 356 // 'orderby' => 'include'. 353 357 $request->set_param( 'orderby', 'include' ); 354 358 $response = rest_get_server()->dispatch( $request );
Note: See TracChangeset
for help on using the changeset viewer.