protected function CakePHPInstallerTest::setCakephpVersion in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/composer/installers/tests/Composer/Installers/Test/CakePHPInstallerTest.php \Composer\Installers\Test\CakePHPInstallerTest::setCakephpVersion()
1 call to CakePHPInstallerTest::setCakephpVersion()
- CakePHPInstallerTest::testGetLocations in vendor/
composer/ installers/ tests/ Composer/ Installers/ Test/ CakePHPInstallerTest.php - Test getLocations returning appropriate values based on CakePHP version
File
- vendor/
composer/ installers/ tests/ Composer/ Installers/ Test/ CakePHPInstallerTest.php, line 106
Class
Namespace
Composer\Installers\TestCode
protected function setCakephpVersion($rm, $version) {
$parser = new VersionParser();
list(, $version) = explode(' ', $parser
->parseConstraints($version));
$installed = new InstalledArrayRepository();
$package = new Package('cakephp/cakephp', $version, $version);
$installed
->addPackage($package);
$rm
->setLocalRepository($installed);
}