Tests: Use a minimal theme for tests.

New default themes require workarounds being added to several unit tests, as they often alter default WordPress behaviour. To avoid ongoing maintenance issues, this change switches to a minimal theme when running tests.

This change also removes the old workarounds for default themes.

Fixes #31550.



git-svn-id: https://develop.svn.wordpress.org/trunk@38858 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Gary Pendergast
2016-10-21 11:02:37 +00:00
parent e7d639345f
commit 9d7e8fec8c
17 changed files with 48 additions and 59 deletions

View File

@@ -53,6 +53,9 @@ $multisite = $multisite || ( defined( 'MULTISITE' ) && MULTISITE );
require_once( dirname( __FILE__ ) . '/mock-mailer.php' );
$phpmailer = new MockPHPMailer();
// Add a symlink to the empty default theme to the themes directory, so it can be used for the tests.
_symlink_default_theme();
system( WP_PHP_BINARY . ' ' . escapeshellarg( dirname( __FILE__ ) . '/install.php' ) . ' ' . escapeshellarg( $config_file_path ) . ' ' . $multisite );
if ( $multisite ) {