mirror of
https://github.com/composer/composer
synced 2025-05-09 00:22:53 +00:00
Explicitly deprecate misuse of the link setters to enforce the fact they expect maps (#10281)
This commit is contained in:
parent
903173ead5
commit
65765a148a
6 changed files with 84 additions and 40 deletions
|
@ -215,13 +215,13 @@ class SolverTest extends TestCase
|
|||
$this->repo->addPackage($extForPhp80 = $this->getPackage('ourcustom/ext-foobar', '1.0'));
|
||||
|
||||
$extForPhp74->setRequires(array(
|
||||
'php' => new Link('ourcustom/ext-foobar', 'ourcustom/PHP', new MultiConstraint(array(
|
||||
'ourcustom/php' => new Link('ourcustom/ext-foobar', 'ourcustom/PHP', new MultiConstraint(array(
|
||||
$this->getVersionConstraint('>=', '7.4.0'),
|
||||
$this->getVersionConstraint('<', '7.5.0'),
|
||||
)), Link::TYPE_REQUIRE),
|
||||
));
|
||||
$extForPhp80->setRequires(array(
|
||||
'php' => new Link('ourcustom/ext-foobar', 'ourcustom/PHP', new MultiConstraint(array(
|
||||
'ourcustom/php' => new Link('ourcustom/ext-foobar', 'ourcustom/PHP', new MultiConstraint(array(
|
||||
$this->getVersionConstraint('>=', '8.0.0'),
|
||||
$this->getVersionConstraint('<', '8.1.0'),
|
||||
)), Link::TYPE_REQUIRE),
|
||||
|
@ -264,13 +264,13 @@ class SolverTest extends TestCase
|
|||
$this->repo->addPackage($extForPhp74 = $this->getPackage('ourcustom/ext-foobar', '1.0'));
|
||||
|
||||
$extForPhp80->setRequires(array(
|
||||
'php' => new Link('ourcustom/ext-foobar', 'ourcustom/PHP', new MultiConstraint(array(
|
||||
'ourcustom/php' => new Link('ourcustom/ext-foobar', 'ourcustom/PHP', new MultiConstraint(array(
|
||||
$this->getVersionConstraint('>=', '8.0.0'),
|
||||
$this->getVersionConstraint('<', '8.1.0'),
|
||||
)), Link::TYPE_REQUIRE),
|
||||
));
|
||||
$extForPhp74->setRequires(array(
|
||||
'php' => new Link('ourcustom/ext-foobar', 'ourcustom/PHP', new MultiConstraint(array(
|
||||
'ourcustom/php' => new Link('ourcustom/ext-foobar', 'ourcustom/PHP', new MultiConstraint(array(
|
||||
$this->getVersionConstraint('>=', '7.4.0'),
|
||||
$this->getVersionConstraint('<', '7.5.0'),
|
||||
)), Link::TYPE_REQUIRE),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue