Tests: Add support for a WP_TESTS_SKIP_INSTALL
environment variable.
Defining `WP_TESTS_SKIP_INSTALL=1` when running tests will skip the install step. While this shouldn't be used for full test runs, it's useful for saving time when running small groups of tests. Props soulseekah. Fixes #43432. git-svn-id: https://develop.svn.wordpress.org/trunk@44536 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
0161a5b70f
commit
0394aab7a8
@ -76,9 +76,11 @@ if ( file_exists( DIR_TESTDATA . '/themedir1' ) ) {
|
||||
$wp_theme_directories[] = DIR_TESTDATA . '/themedir1';
|
||||
}
|
||||
|
||||
system( WP_PHP_BINARY . ' ' . escapeshellarg( dirname( __FILE__ ) . '/install.php' ) . ' ' . escapeshellarg( $config_file_path ) . ' ' . $multisite, $retval );
|
||||
if ( 0 !== $retval ) {
|
||||
exit( $retval );
|
||||
if ( '1' !== getenv( 'WP_TESTS_SKIP_INSTALL' ) ) {
|
||||
system( WP_PHP_BINARY . ' ' . escapeshellarg( dirname( __FILE__ ) . '/install.php' ) . ' ' . escapeshellarg( $config_file_path ) . ' ' . $multisite, $retval );
|
||||
if ( 0 !== $retval ) {
|
||||
exit( $retval );
|
||||
}
|
||||
}
|
||||
|
||||
if ( $multisite ) {
|
||||
|
Loading…
Reference in New Issue
Block a user