mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-05-24 21:24:34 +00:00
Tests: Revert removing empty directory in WP_UnitTestCase_Base::rmdir() for now.
This appears to need more investigation. Instead, delete the `test-plugin` and `link-manager` directories in REST API plugins controller tests, for which this change was initially intended. Follow-up to [54300], [54301], [54303]. See #55652, #56629. git-svn-id: https://develop.svn.wordpress.org/trunk@54304 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -84,7 +84,10 @@ class WP_REST_Plugins_Controller_Test extends WP_Test_REST_Controller_Testcase {
|
||||
|
||||
public function tear_down() {
|
||||
if ( file_exists( WP_PLUGIN_DIR . '/test-plugin/test-plugin.php' ) ) {
|
||||
// Remove plugin files.
|
||||
$this->rmdir( WP_PLUGIN_DIR . '/test-plugin' );
|
||||
// Delete empty directory.
|
||||
rmdir( WP_PLUGIN_DIR . '/test-plugin' );
|
||||
}
|
||||
|
||||
if ( file_exists( DIR_TESTDATA . '/link-manager.zip' ) ) {
|
||||
@@ -92,7 +95,10 @@ class WP_REST_Plugins_Controller_Test extends WP_Test_REST_Controller_Testcase {
|
||||
}
|
||||
|
||||
if ( file_exists( WP_PLUGIN_DIR . '/link-manager/link-manager.php' ) ) {
|
||||
// Remove plugin files.
|
||||
$this->rmdir( WP_PLUGIN_DIR . '/link-manager' );
|
||||
// Delete empty directory.
|
||||
rmdir( WP_PLUGIN_DIR . '/link-manager' );
|
||||
}
|
||||
|
||||
parent::tear_down();
|
||||
|
||||
Reference in New Issue
Block a user