- Timestamp:
- 12/19/2021 01:42:37 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/rest-api/rest-attachments-controller.php
r52068 r52389 523 523 public function test_get_items_invalid_date() { 524 524 $request = new WP_REST_Request( 'GET', '/wp/v2/media' ); 525 $request->set_param( 'after', rand_str());526 $request->set_param( 'before', rand_str());525 $request->set_param( 'after', 'foo' ); 526 $request->set_param( 'before', 'bar' ); 527 527 $response = rest_get_server()->dispatch( $request ); 528 528 $this->assertErrorResponse( 'rest_invalid_param', $response, 400 ); … … 571 571 public function test_get_items_invalid_modified_date() { 572 572 $request = new WP_REST_Request( 'GET', '/wp/v2/media' ); 573 $request->set_param( 'modified_after', rand_str());574 $request->set_param( 'modified_before', rand_str());573 $request->set_param( 'modified_after', 'foo' ); 574 $request->set_param( 'modified_before', 'bar' ); 575 575 $response = rest_get_server()->dispatch( $request ); 576 576 $this->assertErrorResponse( 'rest_invalid_param', $response, 400 );
Note: See TracChangeset
for help on using the changeset viewer.