diff --git a/composer.json b/composer.json index 2ed7ba215..5d24acd8d 100644 --- a/composer.json +++ b/composer.json @@ -68,7 +68,7 @@ }, "autoload-dev": { "psr-4": { - "WordPress\\Plugin_Check\\Test_Data\\": "tests/phpunit/testdata", + "WordPress\\Plugin_Check\\Test_Data\\": "tests/phpunit/testdata/Checks", "WordPress\\Plugin_Check\\Test_Utils\\": "tests/phpunit/utils", "WordPress\\Plugin_Check\\Behat_Utils\\": "tests/behat/includes" } diff --git a/tests/phpunit/tests/Checker/AJAX_Runner_Tests.php b/tests/phpunit/tests/Checker/AJAX_Runner_Tests.php index d60781fab..a8c530ffa 100644 --- a/tests/phpunit/tests/Checker/AJAX_Runner_Tests.php +++ b/tests/phpunit/tests/Checker/AJAX_Runner_Tests.php @@ -84,7 +84,7 @@ function ( $checks ) { $this->assertIsCallable( $cleanup ); - // Assert the Universal_Runtume_Preparation was run. + // Assert the Universal_Runtime_Preparation was run. $this->assertTrue( has_filter( 'option_active_plugins' ) ); $this->assertTrue( has_filter( 'default_option_active_plugins' ) ); $this->assertTrue( has_filter( 'stylesheet' ) ); diff --git a/tests/phpunit/utils/Traits/With_Mock_Filesystem.php b/tests/phpunit/utils/Traits/With_Mock_Filesystem.php index 602657bc3..f4b338bfe 100644 --- a/tests/phpunit/utils/Traits/With_Mock_Filesystem.php +++ b/tests/phpunit/utils/Traits/With_Mock_Filesystem.php @@ -32,7 +32,7 @@ function () { WP_Filesystem(); // Simulate that the original object-cache.copy.php file exists. - $wp_filesystem->put_contents( WP_PLUGIN_CHECK_PLUGIN_DIR_PATH . 'drop-ins/object-cache.copy.php', file_get_contents( WP_PLUGIN_CHECK_PLUGIN_DIR_PATH . 'drop-ins/object-cache.copy.php' ) ); + $wp_filesystem->put_contents( TESTS_PLUGIN_DIR . '/drop-ins/object-cache.copy.php', file_get_contents( TESTS_PLUGIN_DIR . '/drop-ins/object-cache.copy.php' ) ); } /** @@ -59,6 +59,6 @@ function () { WP_Filesystem(); // Simulate that the original object-cache.copy.php file exists. - $wp_filesystem->put_contents( WP_PLUGIN_CHECK_PLUGIN_DIR_PATH . 'drop-ins/object-cache.copy.php', file_get_contents( WP_PLUGIN_CHECK_PLUGIN_DIR_PATH . 'drop-ins/object-cache.copy.php' ) ); + $wp_filesystem->put_contents( TESTS_PLUGIN_DIR . '/drop-ins/object-cache.copy.php', file_get_contents( TESTS_PLUGIN_DIR . '/drop-ins/object-cache.copy.php' ) ); } }