forked from wallabag/wallabag
Jump to Symfony 3.1
This commit is contained in:
22
tests/Wallabag/CoreBundle/Mock/InstallCommandMock.php
Normal file
22
tests/Wallabag/CoreBundle/Mock/InstallCommandMock.php
Normal file
@ -0,0 +1,22 @@
|
||||
<?php
|
||||
|
||||
namespace Tests\Wallabag\CoreBundle\Mock;
|
||||
|
||||
use Wallabag\CoreBundle\Command\InstallCommand;
|
||||
|
||||
/**
|
||||
* This mock aims to speed the test of InstallCommand by avoid calling external command
|
||||
* like all doctrine commands.
|
||||
*
|
||||
* This speed the test but as a downside, it doesn't allow to fully test the InstallCommand
|
||||
*
|
||||
* Launching tests to avoid doctrine command:
|
||||
* phpunit --exclude-group command-doctrine
|
||||
*/
|
||||
class InstallCommandMock extends InstallCommand
|
||||
{
|
||||
protected function runCommand($command, $parameters = [])
|
||||
{
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user