1
0
Fork 0
mirror of https://github.com/composer/composer synced 2025-05-10 09:02:59 +00:00

Fix many PHPStan issues and update baseline

This commit is contained in:
Jordi Boggiano 2021-12-09 22:14:04 +01:00
parent 6ed3aeb343
commit 96486d81cb
No known key found for this signature in database
GPG key ID: 7BBD42C429EC80BC
21 changed files with 252 additions and 361 deletions

View file

@ -49,17 +49,14 @@ class ArchiveCommandTest extends TestCase
$composer->setPackage($package);
$command = $this->getMockBuilder('Composer\Command\ArchiveCommand')
->setMethods(array(
->onlyMethods(array(
'mergeApplicationDefinition',
'bind',
'getSynopsis',
'initialize',
'isInteractive',
'getComposer',
))->getMock();
$command->expects($this->atLeastOnce())->method('getComposer')
->willReturn($composer);
$command->method('isInteractive')->willReturn(false);
$command->run($input, $output);
}
@ -73,12 +70,10 @@ class ArchiveCommandTest extends TestCase
$config = Factory::createConfig();
$command = $this->getMockBuilder('Composer\Command\ArchiveCommand')
->setMethods(array(
->onlyMethods(array(
'mergeApplicationDefinition',
'bind',
'getSynopsis',
'initialize',
'isInteractive',
'getComposer',
'archive',
))->getMock();
@ -96,7 +91,6 @@ class ArchiveCommandTest extends TestCase
false,
null
)->willReturn(0);
$command->method('isInteractive')->willReturn(false);
$this->assertEquals(0, $command->run($input, $output));
}