File tree 1 file changed +5
-1
lines changed
src/Symfony/Bridge/PhpUnit/bin
1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -117,7 +117,11 @@ if (!file_exists("$PHPUNIT_DIR/phpunit-$PHPUNIT_VERSION/phpunit") || md5_file(__
117
117
'requires ' => array ('php ' => '* ' ),
118
118
);
119
119
120
- if (1 === count ($ info ['versions ' ])) {
120
+ $ stableVersions = array_filter ($ info ['versions ' ], function ($ v ) {
121
+ return !preg_match ('/-dev$|^dev-/ ' , $ v );
122
+ });
123
+
124
+ if (!$ stableVersions ) {
121
125
$ passthruOrFail ("$ COMPOSER create-project --ignore-platform-reqs --no-install --prefer-dist --no-scripts --no-plugins --no-progress -s dev phpunit/phpunit phpunit- $ PHPUNIT_VERSION \"$ PHPUNIT_VERSION .* \"" );
122
126
} else {
123
127
$ passthruOrFail ("$ COMPOSER create-project --ignore-platform-reqs --no-install --prefer-dist --no-scripts --no-plugins --no-progress phpunit/phpunit phpunit- $ PHPUNIT_VERSION \"$ PHPUNIT_VERSION .* \"" );
You can’t perform that action at this time.
0 commit comments