public function renderException($message, $exception) { Common::sendHeader('Content-Type: text/plain; charset=utf-8', true); return nl2br($message); }
public function test_renderException_shouldConvertNewLinesToBr() { $response = $this->builder->renderException("The\nerror\nmessage", new \Exception('The other message')); $this->assertEquals('The<br /> error<br /> message', $response); }