Symfony\Component\HttpKernel\Client::filterResponse PHP Method

filterResponse() protected method

Converts the HttpKernel response to a BrowserKit response.
protected filterResponse ( Response $response ) : Symfony\Component\BrowserKit\Response
$response Symfony\Component\HttpFoundation\Response A Response instance
return Symfony\Component\BrowserKit\Response A DomResponse instance
    protected function filterResponse($response)
    {
        // this is needed to support StreamedResponse
        ob_start();
        $response->sendContent();
        $content = ob_get_clean();

        return new DomResponse($content, $response->getStatusCode(), $response->headers->all());
    }