public function testCustomInstallPath()
{
$installer = new Installer($this->io, $this->composer);
$package = new Package('shama/ftp', '1.0.0', '1.0.0');
$package->setType('cakephp-plugin');
$consumerPackage = new RootPackage('foo/bar', '1.0.0', '1.0.0');
$this->composer->setPackage($consumerPackage);
$consumerPackage->setExtra(array('installer-paths' => array('my/custom/path/{$name}/' => array('shama/ftp', 'foo/bar'))));
$result = $installer->getInstallPath($package);
$this->assertEquals('my/custom/path/Ftp/', $result);
}