M6Web\Bundle\PhpProcessManagerBundle\Tests\Units\Command\HttpProcessCommand::testMemoryLimitExit PHP Method

testMemoryLimitExit() public method

public testMemoryLimitExit ( )
    public function testMemoryLimitExit()
    {
        $this->given($loopMock = $this->getLoopMock(), $socketMock = $this->getSocketMock(), $httpServerMock = $this->getHttpServerMock(), $containerMock = $this->getContainer($loopMock, $socketMock, $httpServerMock), $inputMock = $this->getInputMock($port = 8000, $memoryMax = 200, $checkInterval = 60), $outputMock = $this->getOutputMock(), $testedCommand = new TestedCommand(), $testedCommand->setContainer($containerMock), $this->function->memory_get_peak_usage = 412467200)->when($return = $testedCommand->run($inputMock, $outputMock))->then->mock($socketMock)->call('listen')->withArguments($port)->once()->mock($loopMock)->call('addPeriodicTimer')->withAtLeastArguments([$inputMock->getOption('check-interval')])->once()->call('run')->once()->call('stop')->once()->integer($return)->isEqualTo(10);
    }