1
0
Fork 0

Add workaround for InstalledVersion to ensure we always run last version

pull/12269/head
Jordi Boggiano 2025-01-21 10:47:41 +01:00
parent ee6dc33fd1
commit d2cd6dec2d
No known key found for this signature in database
1 changed files with 3 additions and 0 deletions

View File

@ -19,6 +19,9 @@ if (function_exists('date_default_timezone_set') && function_exists('date_defaul
}
require __DIR__.'/../src/bootstrap.php';
// ensure we always use the latest InstalledVersions.php even if an older composer ran the install, but we need
// to have it included from vendor dir and not from src/ otherwise some gated check in the code will not work
copy(__DIR__.'/../src/Composer/InstalledVersions.php', __DIR__.'/../vendor/composer/InstalledVersions.php');
require __DIR__.'/../vendor/composer/InstalledVersions.php';
Platform::putEnv('COMPOSER_TESTS_ARE_RUNNING', '1');