private function StackedHttpKernelTest::getDelegatingTerminableMock in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/stack/builder/tests/unit/Stack/StackedHttpKernelTest.php \Stack\StackedHttpKernelTest::getDelegatingTerminableMock()
File
- vendor/
stack/ builder/ tests/ unit/ Stack/ StackedHttpKernelTest.php, line 95
Class
Namespace
StackCode
private function getDelegatingTerminableMock(TerminableInterface $next) {
$app = $this
->getMock('Stack\\TerminableHttpKernel');
$app
->expects($this
->once())
->method('terminate')
->with($this
->isInstanceOf('Symfony\\Component\\HttpFoundation\\Request'), $this
->isInstanceOf('Symfony\\Component\\HttpFoundation\\Response'))
->will($this
->returnCallback(function ($request, $response) use ($next) {
$next
->terminate($request, $response);
}));
return $app;
}