fourth_try.diff on Ticket #23066 – Attachment
Ticket #23066: fourth_try.diff
File fourth_try.diff,
(added by chriscct7, 8 months ago)
Fourth Try Diff
index c3aa298..b846eef 100644
77error_reporting( E_ALL & ~E_DEPRECATED & ~E_STRICT ); 88 99$config_file_path = $argv[1]; 10 11 $config_dir = dirname( $config_file_path ); 10$multisite = ! empty( $argv[2] ); 1211 1312define( 'WP_INSTALLING', true ); 1413require_once $config_file_path; 15 require_once $config_dir . '/lib/functions.php'; 14require_once dirname( $config_file_path ) . '/lib/functions.php'; 1615 1716$_SERVER['SERVER_PROTOCOL'] = 'HTTP/1.1'; 1817$_SERVER['HTTP_HOST'] = WP_TESTS_DOMAIN; …
foreach ( $wpdb->tables() as $table => $prefixed_table ) { 4645foreach ( $wpdb->tables( 'ms_global' ) as $table => $prefixed_table ) { 4746 $wpdb->query( "DROP TABLE IF EXISTS $prefixed_table" ); 4847 49 if ( defined('WP_ALLOW_MULTISITE') && WP_ALLOW_MULTISITE ) { 48 // We need to create references to ms global tables. 49 if ( $multisite ) 5050 $wpdb->$table = $prefixed_table; 5151} 5252 53 if ( defined('WP_ALLOW_MULTISITE') && WP_ALLOW_MULTISITE ) { 53wp_install( WP_TESTS_TITLE, 'admin', WP_TESTS_EMAIL, true, null, 'password' ); 54 55if ( $multisite ) { 5456 echo "Installing network..." . PHP_EOL; 5557 5658 define( 'WP_INSTALLING_NETWORK', true ); 5759 58 install_network(); 59 populate_network( 1, WP_TESTS_DOMAIN, WP_TESTS_EMAIL, WP_TESTS_NETWORK_TITLE, '/', WP_TESTS_SUBDOMAIN_INSTALL ); 60 $title = WP_TESTS_TITLE . ' Network'; 61 $subdomain_install = false; 6062 61 //system( WP_PHP_BINARY . ' ' . escapeshellarg( dirname( __FILE__ ) . '/ms-install.php' ) . ' ' . escapeshellarg( $config_file_path ) ); 63 install_network(); 64 populate_network( 1, WP_TESTS_DOMAIN, WP_TESTS_EMAIL, $title, '/', $subdomain_install ); 6265} 6366 64 file_put_contents( WP_TESTS_VERSION_FILE, test_version_check_hash() ); 65 No newline at end of file 67file_put_contents( WP_TESTS_VERSION_FILE, $hash ); 68 No newline at end of file Download in other formats:
fourth_try.diff on Ticket #23066 – Attachment
Ticket #23066: fourth_try.diff
File fourth_try.diff,
(added by chriscct7, 8 months ago)
Fourth Try Diff
index c3aa298..b846eef 100644
77error_reporting( E_ALL & ~E_DEPRECATED & ~E_STRICT ); 88 99$config_file_path = $argv[1]; 10 11 $config_dir = dirname( $config_file_path ); 10$multisite = ! empty( $argv[2] ); 1211 1312define( 'WP_INSTALLING', true ); 1413require_once $config_file_path; 15 require_once $config_dir . '/lib/functions.php'; 14require_once dirname( $config_file_path ) . '/lib/functions.php'; 1615 1716$_SERVER['SERVER_PROTOCOL'] = 'HTTP/1.1'; 1817$_SERVER['HTTP_HOST'] = WP_TESTS_DOMAIN; …
foreach ( $wpdb->tables() as $table => $prefixed_table ) { 4645foreach ( $wpdb->tables( 'ms_global' ) as $table => $prefixed_table ) { 4746 $wpdb->query( "DROP TABLE IF EXISTS $prefixed_table" ); 4847 49 if ( defined('WP_ALLOW_MULTISITE') && WP_ALLOW_MULTISITE ) { 48 // We need to create references to ms global tables. 49 if ( $multisite ) 5050 $wp
db->$table = $prefixed_table; 5151} 5252 53 if ( defined('WP_ALLOW_MULTISITE') && WP_ALLOW_MULTISITE ) { 53wp_install( WP_TESTS_TITLE, 'admin', WP_TESTS_EMAIL, true, null, 'password' ); 54 55if ( $multisite ) { 5456 echo "Installing network..." . PHP_EOL; 5557 5658 define( 'WP_INSTALLING_NETWORK', true ); 5759 58 install_network(); 59 populate_network( 1, WP_TESTS_DOMAIN, WP_TESTS_EMAIL, WP_TESTS_NETWORK_TITLE, '/', WP_TESTS_SUBDOMAIN_INSTALL ); 60 $title = WP_TESTS_TITLE . ' Network'; 61 $subdomain_install = false; 6062 61 //system( WP_PHP_BINARY . ' ' . escapeshellarg( dirname( __FILE__ ) . '/ms-install.php' ) . ' ' . escapeshellarg( $config_file_path ) ); 63 install_network(); 64 populate_network( 1, WP_TESTS_DOMAIN, WP_TESTS_EMAIL, $title, '/', $subdomain_install ); 6265} 6366 64 file_put_contents( WP_TESTS_VERSION_FILE, test_version_check_hash() ); 65 No newline at end of file 67file_put_contents( WP_TESTS_VERSION_FILE, $hash ); 68 No newline at end of file Download in other formats: