1
0
Fork 0
mirror of https://github.com/composer/composer synced 2025-05-09 00:22:53 +00:00

Added support for the alias of an aliased package

This commit is contained in:
Martin Hasoň 2013-04-01 08:10:15 +02:00
parent c39e958a6f
commit 753a8345cb
14 changed files with 120 additions and 119 deletions

View file

@ -123,4 +123,18 @@ class ArrayLoaderTest extends \PHPUnit_Framework_TestCase
$dumper = new ArrayDumper;
$this->assertEquals($config, $dumper->dump($package));
}
public function testPackageWithBranchAlias()
{
$config = array(
'name' => 'A',
'version' => 'dev-master',
'extra' => array('branch-alias' => array('dev-master' => '1.0.x-dev')),
);
$package = $this->loader->load($config);
$this->assertInstanceOf('Composer\Package\AliasPackage', $package);
$this->assertEquals('1.0.x-dev', $package->getPrettyVersion());
}
}