WordPress.org

Make WordPress Core

Ticket #40270: 40270.2.diff

File 40270.2.diff, 904 bytes (added by dlh, 2 years ago)
  • tests/phpunit/tests/rest-api/rest-posts-controller.php

     
    28352835                $request->set_param( 'force', 'false' );
    28362836                $response = $this->server->dispatch( $request );
    28372837
    2838                 $this->assertNotInstanceOf( 'WP_Error', $response );
    28392838                $this->assertEquals( 200, $response->get_status() );
    28402839                $data = $response->get_data();
    28412840                $this->assertEquals( 'Deleted post', $data['title']['raw'] );
     
    28502849                $request['force'] = true;
    28512850                $response = $this->server->dispatch( $request );
    28522851
    2853                 $this->assertNotInstanceOf( 'WP_Error', $response );
    28542852                $this->assertEquals( 200, $response->get_status() );
    28552853                $data = $response->get_data();
    28562854                $this->assertTrue( $data['deleted'] );