/** * @test */ public function replaceHttpResponseReplacesTheCurrentResponse() { /** @var Response $mockNewHttpResponse */ $mockNewHttpResponse = $this->getMockBuilder('TYPO3\\Flow\\Http\\Response')->disableOriginalConstructor()->getMock(); $this->componentContext->replaceHttpResponse($mockNewHttpResponse); $this->assertSame($mockNewHttpResponse, $this->componentContext->getHttpResponse()); }