WordPress.org

Make WordPress Core


Ignore:
Timestamp:
02/27/2021 05:08:26 PM (11 months ago)
Author:
johnbillion
Message:

Build/Test Tools: Fix and standardise calls to the tearDown() method in the test suite.

The parent method should be called after any test-specific teardown.

See #52625

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/includes/testcase-rest-controller.php

    r46586 r50450  
    1515
    1616    public function tearDown() {
    17         parent::tearDown();
    1817        remove_filter( 'rest_url', array( $this, 'test_rest_url_for_leading_slash' ), 10, 2 );
    1918        /** @var WP_REST_Server $wp_rest_server */
    2019        global $wp_rest_server;
    2120        $wp_rest_server = null;
     21        parent::tearDown();
    2222    }
    2323
Note: See TracChangeset for help on using the changeset viewer.