N98\Magento\Command\Developer\Module\Rewrite\ConflictsCommandTest::getCommandWithMockLoadRewrites PHP Метод

getCommandWithMockLoadRewrites() приватный Метод

Mock the ConflictsCommand and change the return value of loadRewrites() to the given argument
private getCommandWithMockLoadRewrites ( array $return ) : ConflictsCommand
$return array
Результат ConflictsCommand
    private function getCommandWithMockLoadRewrites(array $return)
    {
        $commandMock = $this->getMockBuilder('N98\\Magento\\Command\\Developer\\Module\\Rewrite\\ConflictsCommand')->setMockClassName('ConflictsCommandMock')->enableOriginalClone()->setMethods(array('loadRewrites'))->getMock();
        $this->getApplication()->add($commandMock);
        $commandMock->expects($this->any())->method('loadRewrites')->will($this->returnValue($return));
        return $commandMock;
    }