@@ -38,7 +38,7 @@ final class MakerTestEnvironment
3838 private function __construct (
3939 private MakerTestDetails $ testDetails ,
4040 ) {
41- $ this ->isWindows = str_contains ( strtolower (\ PHP_OS ), ' win ' ) ;
41+ $ this ->isWindows = '\\' === \ DIRECTORY_SEPARATOR ;
4242
4343 $ this ->fs = new Filesystem ();
4444 $ this ->rootPath = realpath (__DIR__ .'/../../ ' );
@@ -151,7 +151,7 @@ public function prepareDirectory(): void
151151 try {
152152 // let's do some magic here git is faster than copy
153153 MakerTestProcess::create (
154- '\\' === \ DIRECTORY_SEPARATOR ? 'git clone %FLEX_PATH% %APP_PATH% ' : 'git clone "$FLEX_PATH" "$APP_PATH" ' ,
154+ $ this -> isWindows ? 'git clone %FLEX_PATH% %APP_PATH% ' : 'git clone "$FLEX_PATH" "$APP_PATH" ' ,
155155 \dirname ($ this ->flexPath ),
156156 [
157157 'FLEX_PATH ' => $ this ->flexPath ,
@@ -269,7 +269,7 @@ private function buildFlexSkeleton(): void
269269 MakerTestProcess::create ('composer require phpunit:1.1.* browser-kit symfony/css-selector --prefer-dist --no-progress --no-suggest ' , $ this ->flexPath )
270270 ->run ();
271271
272- if ('\\' !== \ DIRECTORY_SEPARATOR ) {
272+ if (! $ this -> isWindows ) {
273273 $ this ->fs ->remove ($ this ->flexPath .'/vendor/symfony/phpunit-bridge ' );
274274
275275 $ this ->fs ->symlink ($ rootPath .'/vendor/symfony/phpunit-bridge ' , $ this ->flexPath .'/vendor/symfony/phpunit-bridge ' );
0 commit comments