mirror of
https://github.com/composer/composer
synced 2025-05-09 00:22:53 +00:00
Create an impossible rule when trying to install something that doesn't exist.
The rule isn't acted upon yet (hence the incomplete test) but it is there as a reminder that this case needs to be handled.
This commit is contained in:
parent
c97a33577b
commit
eafe13d5a5
2 changed files with 22 additions and 0 deletions
|
@ -55,6 +55,22 @@ class SolverTest extends TestCase
|
|||
));
|
||||
}
|
||||
|
||||
public function testInstallNonExistingPackageFails()
|
||||
{
|
||||
$this->repo->addPackage($this->getPackage('A', '1.0'));
|
||||
$this->reposComplete();
|
||||
|
||||
$this->request->install('B');
|
||||
|
||||
try {
|
||||
$transaction = $this->solver->solve($this->request);
|
||||
$this->markTestIncomplete('Reporting this failure is not implemented/working yet');
|
||||
//$this->fail('Unsolvable conflict did not resolve in exception.');
|
||||
} catch (SolverProblemsException $e) {
|
||||
// @todo: assert problem properties
|
||||
}
|
||||
}
|
||||
|
||||
public function testSolverInstallWithDeps()
|
||||
{
|
||||
$this->repo->addPackage($packageA = $this->getPackage('A', '1.0'));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue