Tests: Remove `test_new_files_are_not_in_old_files_array()` from [36843].

The test assumes that if a CSS file was added to `$_old_files` all three files (.css, .min.css, -rtl.min.css; it's actually missing the fourth case, -rtl.css) don't exist anymore. But this isn't always the case. The test is also incredible slow because it does three `file_exists()` checks for each file — the global contains 646 files currently.

It's important what we have in the /build directory and that's covered by `test_new_files_are_not_in_old_files_array_compiled()`.

Fixes #36083.

git-svn-id: https://develop.svn.wordpress.org/trunk@36885 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Dominik Schilling (ocean90) 2016-03-08 16:44:25 +00:00
parent 7826b7b205
commit 5064747619
1 changed files with 0 additions and 19 deletions

View File

@ -19,30 +19,11 @@ class Tests_Admin_IncludesUpdateCore extends WP_UnitTestCase {
return $files;
}
/**
* Ensure no project files are inside `$_old_files`.
*
* @ticket 36083
*
* @dataProvider data_old_files
*
* @param string $file File name.
*/
public function test_new_files_are_not_in_old_files_array( $file ) {
$this->assertFalse( file_exists( ABSPATH . $file ) );
$this->assertFalse( file_exists( ABSPATH . str_replace( '.min.', '.', $file ) ) );
$this->assertFalse( file_exists( ABSPATH . str_replace( '-rtl.min.', '.', $file ) ) );
}
/**
* Ensure no project files are inside `$_old_files` in the build directory.
*
* The previous test confirms that no existing files are inside `$_old_files`.
* However, we must also confirm that these do not exist in the final build.
*
* @ticket 36083
*
* @depends test_new_files_are_not_in_old_files_array
* @dataProvider data_old_files
*
* @param string $file File name.