Files
n98-magerun2/dev/tests/N98/Magento/Command/Developer/TemplateHintsBlocksCommandTest.php
T
Tom Klingenberg bdebdb1753 [FIX] WS fixes
- no newline at the end of file
2015-11-11 01:18:16 +01:00

39 lines
1.2 KiB
PHP

<?php
namespace N98\Magento\Command\Developer;
use Symfony\Component\Console\Tester\CommandTester;
use N98\Magento\Command\PHPUnit\TestCase;
class TemplateHintsBlocksCommandTest extends TestCase
{
public function testExecute()
{
$application = $this->getApplication();
$application->add(new TemplateHintsBlocksCommand());
$application->setAutoExit(false);
$command = $this->getApplication()->find('dev:template-hints-blocks');
$commandTester = new CommandTester($command);
$commandTester->execute(
array(
'command' => $command->getName(),
'--on' => true,
'store' => 'admin',
)
);
$this->assertRegExp('/Template Hints Blocks enabled/', $commandTester->getDisplay());
$commandTester = new CommandTester($command);
$commandTester->execute(
array(
'command' => $command->getName(),
'--off' => true,
'store' => 'admin',
)
);
$this->assertRegExp('/Template Hints Blocks disabled/', $commandTester->getDisplay());
}
}