@@ -24,14 +24,14 @@ if (!file_exists($COMPOSER = __DIR__.'/composer.phar')) {
24
24
$ PHP = ProcessUtils::escapeArgument ($ PHP );
25
25
$ COMPOSER = $ PHP .' ' .ProcessUtils::escapeArgument ($ COMPOSER );
26
26
27
- if (!file_exists ("$ PHPUNIT_DIR /phpunit- $ PHPUNIT_VERSION /phpunit " ) || md5_file (__FILE__ ) !== @file_get_contents ("$ PHPUNIT_DIR /.md5 " ) || ( isset ( $ argv [ 1 ]) && ' install ' === $ argv [ 1 ]) ) {
27
+ if (!file_exists ("$ PHPUNIT_DIR /phpunit- $ PHPUNIT_VERSION /phpunit " ) || md5_file (__FILE__ ) !== @file_get_contents ("$ PHPUNIT_DIR /.md5 " )) {
28
28
// Build a standalone phpunit without symfony/yaml
29
29
30
30
$ oldPwd = getcwd ();
31
31
@mkdir ($ PHPUNIT_DIR );
32
32
chdir ($ PHPUNIT_DIR );
33
33
if (file_exists ("phpunit- $ PHPUNIT_VERSION " )) {
34
- passthru (sprintf ('\\' === DIRECTORY_SEPARATOR ? 'del /S /F /Q %s & rmdir %1$s >nul 2>&1 ' : 'rm -rf %s ' , "phpunit- $ PHPUNIT_VERSION " ));
34
+ passthru (sprintf ('\\' === DIRECTORY_SEPARATOR ? '( del /S /F /Q %s & rmdir %1$s) >nul ' : 'rm -rf %s ' , "phpunit- $ PHPUNIT_VERSION " ));
35
35
}
36
36
if (extension_loaded ('openssl ' ) && ini_get ('allow_url_fopen ' )) {
37
37
stream_copy_to_stream (fopen ("https://github.com/sebastianbergmann/phpunit/archive/ $ PHPUNIT_VERSION .zip " , 'rb ' ), fopen ("$ PHPUNIT_VERSION .zip " , 'wb ' ));
58
58
);
59
59
chdir ('.. ' );
60
60
if (file_exists ('../src/Symfony/Bridge/PhpUnit ' ) && `git diff --name-only HEAD^ -- ../src/Symfony/Bridge/PhpUnit `) {
61
- passthru (sprintf ('\\' === DIRECTORY_SEPARATOR ? 'del /S /F /Q %s & rmdir %1$s >nul 2>&1 ' : 'rm -rf %s ' , str_replace ('/ ' , DIRECTORY_SEPARATOR , "phpunit- $ PHPUNIT_VERSION /vendor/symfony/phpunit-bridge " )));
61
+ passthru (sprintf ('\\' === DIRECTORY_SEPARATOR ? '( del /S /F /Q %s & rmdir %1$s) >nul ' : 'rm -rf %s ' , str_replace ('/ ' , DIRECTORY_SEPARATOR , "phpunit- $ PHPUNIT_VERSION /vendor/symfony/phpunit-bridge " )));
62
62
symlink (realpath ('../src/Symfony/Bridge/PhpUnit ' ), "phpunit- $ PHPUNIT_VERSION /vendor/symfony/phpunit-bridge " );
63
63
}
64
64
file_put_contents ('.md5 ' , md5_file (__FILE__ ));
0 commit comments