Hypernode\Magento\Command\Hypernode\Patches\ListCommandTest::testExecute PHP Method

testExecute() public method

public testExecute ( )
    public function testExecute()
    {
        $command = $this->getCommand();
        $curl = $this->getMock(Curl::class, ['get']);
        $curl->expects($this->once())->method('get')->with($this->stringStartsWith($command::HYPERNODE_PATCH_TOOL_URL));
        $curl->response = json_encode(array('required' => ["SUPEE-01234"]));
        // Set mock
        $command->setCurl($curl);
        $commandTester = new CommandTester($command);
        $commandTester->execute([]);
        $this->assertRegExp('/SUPEE\\-01234/', $commandTester->getDisplay());
    }