mirror of
https://github.com/composer/composer
synced 2025-05-09 00:22:53 +00:00
Refactor away some unnecessary RepositorySet usages
This commit is contained in:
parent
f35cd8948a
commit
c5c6d44a0b
3 changed files with 38 additions and 29 deletions
|
@ -134,7 +134,7 @@ class PluginInstallerTest extends TestCase
|
|||
public function testInstallNewPlugin()
|
||||
{
|
||||
$this->repository
|
||||
->expects($this->once())
|
||||
->expects($this->any())
|
||||
->method('getPackages')
|
||||
->will($this->returnValue(array()));
|
||||
$installer = new PluginInstaller($this->io, $this->composer);
|
||||
|
@ -150,7 +150,7 @@ class PluginInstallerTest extends TestCase
|
|||
public function testInstallMultiplePlugins()
|
||||
{
|
||||
$this->repository
|
||||
->expects($this->once())
|
||||
->expects($this->any())
|
||||
->method('getPackages')
|
||||
->will($this->returnValue(array($this->packages[3])));
|
||||
$installer = new PluginInstaller($this->io, $this->composer);
|
||||
|
@ -169,7 +169,7 @@ class PluginInstallerTest extends TestCase
|
|||
public function testUpgradeWithNewClassName()
|
||||
{
|
||||
$this->repository
|
||||
->expects($this->once())
|
||||
->expects($this->any())
|
||||
->method('getPackages')
|
||||
->will($this->returnValue(array($this->packages[0])));
|
||||
$this->repository
|
||||
|
@ -190,7 +190,7 @@ class PluginInstallerTest extends TestCase
|
|||
public function testUninstall()
|
||||
{
|
||||
$this->repository
|
||||
->expects($this->once())
|
||||
->expects($this->any())
|
||||
->method('getPackages')
|
||||
->will($this->returnValue(array($this->packages[0])));
|
||||
$this->repository
|
||||
|
@ -210,7 +210,7 @@ class PluginInstallerTest extends TestCase
|
|||
public function testUpgradeWithSameClassName()
|
||||
{
|
||||
$this->repository
|
||||
->expects($this->once())
|
||||
->expects($this->any())
|
||||
->method('getPackages')
|
||||
->will($this->returnValue(array($this->packages[1])));
|
||||
$this->repository
|
||||
|
@ -230,7 +230,7 @@ class PluginInstallerTest extends TestCase
|
|||
public function testRegisterPluginOnlyOneTime()
|
||||
{
|
||||
$this->repository
|
||||
->expects($this->once())
|
||||
->expects($this->any())
|
||||
->method('getPackages')
|
||||
->will($this->returnValue(array()));
|
||||
$installer = new PluginInstaller($this->io, $this->composer);
|
||||
|
@ -330,7 +330,7 @@ class PluginInstallerTest extends TestCase
|
|||
public function testCommandProviderCapability()
|
||||
{
|
||||
$this->repository
|
||||
->expects($this->once())
|
||||
->expects($this->any())
|
||||
->method('getPackages')
|
||||
->will($this->returnValue(array($this->packages[7])));
|
||||
$installer = new PluginInstaller($this->io, $this->composer);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue